unfeltboy 发表于 2008-4-4 21:26:00

VBA中如如设计宋体字体?

<p>VBA中如何将文字样式的字体设置为宋体,TxtStyle.Name="宋体" 或TxtStyle.Name="simsun.ttf" 或TxtStyle.Name="simsun.ttc"</p><p>都通不过,不知道该如何呢?</p>

azjmjsj 发表于 2008-4-6 20:49:00

<p><a href="http://bbs.mjtd.com/forum.php?mod=viewthread&tid=24260">http://bbs.mjtd.com/forum.php?mod=viewthread&tid=24260</a></p><p></p><p></p><p>***************************************************<br/>西北凡人http://www.abofanyi.com/blog</p><p></p>

billtanglu 发表于 2008-4-9 09:40:00

Public Sub 字体样式() '============设置字体============<br/>&nbsp;Dim typeface As String<br/>&nbsp;Dim textbold As Boolean<br/>&nbsp;Dim textitalic As Boolean<br/>&nbsp;Dim textcharset As Long<br/>&nbsp;Dim textpfamily As Long<br/>&nbsp; acadDoc.ActiveTextStyle.GetFont typeface, textbold, textitalic, textcharset, textpfamily<br/>&nbsp; typeface = "宋体"<br/>&nbsp; acadDoc.ActiveTextStyle.SetFont typeface, textbold, textitalic, textcharset, textpfamily<br/>&nbsp; acadDoc.Regen acActiveViewport<br/>End Sub

thokay 发表于 2012-7-3 09:59:54

写了,灰常有用

thokay 发表于 2012-7-3 10:00:32

billtanglu 发表于 2008-4-9 09:40 static/image/common/back.gif
Public Sub 字体样式() '============设置字体============&nbsp;Dim typeface As String&nbsp;Dim textbol ...

谢啦,灰常有用
页: [1]
查看完整版本: VBA中如如设计宋体字体?