在线翻译+AutoCAD VBA帮助文件----玩转AutoCAD VBA
本帖最后由 作者 于 2007-12-20 14:20:25 编辑 <br /><br /> <p>我的学习经验是:</p><p>下载免费的有道桌面词典--翻译AutoCAD的VBA帮助文件,玩转AutoCAD VBA如虎天羽。</p><p>以“Text”为例,抛砖引玉掌握AutoCAD VBA的属性。</p><p><table cellspacing="0" cellpadding="0" width="531" border="0" style="WIDTH: 398pt; BORDER-COLLAPSE: collapse;"><colgroup><col width="188" style="WIDTH: 141pt; mso-width-source: userset; mso-width-alt: 6016;"></col><col></col><col width="135" style="WIDTH: 101pt; mso-width-source: userset; mso-width-alt: 4320;"></col><col></col><col width="208" style="WIDTH: 156pt; mso-width-source: userset; mso-width-alt: 6656;"></col><col></col></colgroup><tbody><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" width="188" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; WIDTH: 141pt; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Properties<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" width="135" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; WIDTH: 101pt; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">文本属性</font></td><td class="xl24" width="208" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; WIDTH: 156pt; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">测试</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Application<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">应用</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">需进一步学习</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Alignment<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">调整</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Backward<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">置于底层</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Document<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">文件</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">需进一步学习</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Handle<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">句柄</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">HasExtensionDictionary<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">扩展字典</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">需进一步学习</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Height<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">高度</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">HorizontalAlignment<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">水平调整</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Hyperlinks<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">超级连接</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">需进一步学习</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">InsertionPoint<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">插入点</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Layer<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">图层</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Linetype<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">线性</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">LinetypeScale<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">线性比例</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Lineweight<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">线宽度</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Normal<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">标准模式</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">需进一步学习</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">ObjectID<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">对象编号</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">ObjectName<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">对象名</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">ObliqueAngle<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">倾斜角</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">OwnerID<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">所有者编号</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">需进一步学习</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">PlotStyleName<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">画图格式名称</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">需进一步学习</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Rotation<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">旋转</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">ScaleFactor<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">比例因子</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">StyleName<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">格式名</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">TextAlignmentPoint<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">文本调整点</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">TextGenerationFlag<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">文本产生标识</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">需进一步学习</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">TextString<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">文本字符串</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">Thickness<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">厚度</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">需进一步学习</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">TrueColor<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">本色</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">UpsideDown<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">向下颠倒</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font size="1"><font face="宋体">VerticalAlignment<span style="mso-spacerun: yes;"> </font></font></span></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">垂直调整</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr><tr height="19" style="HEIGHT: 14.25pt;"><td class="xl24" height="19" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; HEIGHT: 14.25pt; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">Visible </font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">可见性</font></td><td class="xl24" style="BORDER-RIGHT: #ece9d8; BORDER-TOP: #ece9d8; BORDER-LEFT: #ece9d8; BORDER-BOTTOM: #ece9d8; BACKGROUND-COLOR: transparent;"><font face="宋体" size="1">实例通过</font></td></tr></tbody></table></p> <p>查Help文件的Text。</p><p>掌握以下Text属性变化无穷,编程应用能得心应手。</p><p>Sub ttt()<br/> Dim Ent As AcadEntity<br/> Dim tt As AcadText<br/> Dim retcolor As AcadAcCmColor</p><p> For Each tt In ThisDrawing.ModelSpace<br/> With tt<br/> Debug.Print ".textString 文本字符串", .textString<br/> Debug.Print "---------"<br/> <br/> Debug.Print ".Alignment 调整", .Alignment<br/> Debug.Print "---------"<br/> Debug.Print ".Backward 置后", .Backward<br/> Debug.Print "---------"<br/> Debug.Print ".Handle句柄 ", .Handle<br/> Debug.Print ".HasExtensionDictionary 扩展字典 ", .HasExtensionDictionary<br/> Debug.Print ".height 文本高度", .height<br/> Debug.Print "---------"<br/> Debug.Print "insertionPoint 插入点 ", .insertionPoint(0), .insertionPoint(1)<br/> Debug.Print "---------"<br/> Debug.Print ".Layer 图层 ", .Layer<br/> Debug.Print ".Linetype 线性", .Linetype<br/> Debug.Print ".LinetypeScale 线性比例 ", .LinetypeScale<br/> Debug.Print ".Lineweight 线性宽度 ", .Lineweight<br/> Debug.Print "---------"<br/>' Debug.Print .Normal 如何应用继续研究</p><p> Debug.Print "---------"<br/> Debug.Print ".ObjectID 对象标识号 ", .ObjectID<br/> Debug.Print ".ObjectName 对象名称 ", .ObjectName<br/> Debug.Print ".ObliqueAngle 倾斜角 ", .ObliqueAngle<br/> Debug.Print ".OwnerID 所有者标识号 ", .OwnerID '与ObjectID有何区别<br/> Debug.Print "---------"<br/> Debug.Print ".PlotStyleName 绘图格式名 ", .PlotStyleName<br/> Debug.Print "---------"<br/> Debug.Print ".Rotation 旋转角 ", .Rotation<br/> Debug.Print "---------"<br/> Debug.Print ".ScaleFactor 比例因子 ", .ScaleFactor<br/> Debug.Print ".StyleName 字型格式名称 ", .StyleName<br/> Debug.Print "---------"<br/> Debug.Print ".TextAlignmentPoint 文本调整点 ", .TextAlignmentPoint(0), .TextAlignmentPoint(1)<br/> Debug.Print ".TextGenerationFlag 文本形成(产生)", .TextGenerationFlag<br/> Debug.Print ".Thickness 厚度 ", .Thickness<br/> <br/> Set retcolor = .TrueColor<br/> Debug.Print "文本颜色 ", retcolor.ColorIndex, "文本实体颜色 ", retcolor.EntityColor<br/> <br/> Debug.Print "---------"<br/> Debug.Print ".UpsideDown 颠倒 ", .UpsideDown<br/> Debug.Print "---------"<br/> Debug.Print ".Visible 可见性 ", .Visible<br/> <br/> End With<br/> Next tt<br/>End Sub<br/></p><p>运行结果如下:</p><p>.textString 文本字符串 测试文本<br/>---------<br/>.Alignment 调整 1 <br/>---------<br/>.Backward 置后 True<br/>---------<br/>.Handle句柄 1CA<br/>.HasExtensionDictionary 扩展字典 False<br/>.height 文本高度 5 <br/>---------<br/>insertionPoint 插入点 6.82904314137626 5.24248999382424 <br/>---------<br/>.Layer 图层 0<br/>.Linetype 线性 ByLayer<br/>.LinetypeScale 线性比例 1 <br/>.Lineweight 线性宽度 -1 <br/>---------<br/>---------<br/>.ObjectID 对象标识号 2130110800 <br/>.ObjectName 对象名称 AcDbText<br/>.ObliqueAngle 倾斜角 .349065850398866 <br/>.OwnerID 所有者标识号 2130001144 <br/>---------<br/>.PlotStyleName 绘图格式名 颜色_6<br/>---------<br/>.Rotation 旋转角 .523598775598299 <br/>---------<br/>.ScaleFactor 比例因子 1 <br/>.StyleName 字型格式名称 Standard<br/>---------<br/>.TextAlignmentPoint 文本调整点 .333852612992966 1.49248999382424 <br/>.TextGenerationFlag 文本形成(产生) 6 <br/>.Thickness 厚度 0 <br/>文本颜色 6 文本实体颜色 -1023410170 <br/>---------<br/>.UpsideDown 颠倒 True<br/>---------<br/>.Visible 可见性 True</p> <p>在线翻译+AUTOCad's Help掌握Line属性</p><p>Sub ll()<br/> Dim ll As AcadLine<br/> Dim myApp As AcadApplication<br/> <br/> For Each ll In ThisDrawing.ModelSpace<br/> With ll<br/> Debug.Print "ll.Angle", ll.Angle<br/> 'Debug.Print ll.Application(0)<br/> Debug.Print "Delta ", ll.Delta(0), ll.Delta(1), ll.Delta(2)<br/> 'Debug.Print ll.Document<br/> Debug.Print "Handle ", ll.Handle<br/> Debug.Print "Layer ", ll.Layer<br/> Debug.Print "Layer ", ll.Length<br/> Debug.Print "Linetype ", ll.Linetype<br/> Debug.Print "LinetypeScale ", ll.LinetypeScale<br/> Debug.Print "ObjectID ", ll.ObjectID<br/> Debug.Print "ObjectName ", ll.ObjectName<br/> Set myApp = ll.Application<br/> Debug.Print "Gets the Application object.获取应用对象:", myApp.Name<br/> <br/> End With<br/> ll.Update<br/> Next ll<br/> </p><p>结果-Result:</p><p>ll.Angle .602057916401675 <br/>Delta 566.011368148818 388.94160685795 0 <br/>Handle 87<br/>Layer 0<br/>Layer 686.763745708043 <br/>Linetype ACAD_ISO06W100<br/>LinetypeScale 2 <br/>ObjectID 2130001528 <br/>ObjectName AcDbLine<br/>Gets the Application object.获取应用对象: AutoCAD<br/>ll.Angle .785398163397448 <br/>Delta 2 2 0 <br/>Handle 8F<br/>Layer 0<br/>Layer 2.82842712474619 <br/>Linetype ByLayer<br/>LinetypeScale 1 <br/>ObjectID 2130001592 <br/>ObjectName AcDbLine<br/>Gets the Application object.获取应用对象: AutoCAD<br/>ll.Angle .785398163397448 <br/>Delta 2 2 0 <br/>Handle 90<br/>Layer 0<br/>Layer 2.82842712474619 <br/>Linetype ByLayer<br/>LinetypeScale 1 <br/>ObjectID 2130001600 <br/>ObjectName AcDbLine<br/>Gets the Application object.获取应用对象: AutoCAD</p> <p>翻译软件+查AutoCAD VBA帮助文件</p><p>Arc属性</p><p>Sub Arc_Attribute()<br/> Dim ArcAa As AcadArc, tt As AcadText<br/> Dim currDoc As AcadDocument<br/> <br/> For Each ArcAa In ThisDrawing.ModelSpace<br/> With ArcAa<br/> Debug.Print ".ArcLength 弧弦长", .ArcLength<br/> Debug.Print ".Area 弧面积", .Area<br/> Debug.Print "中心点坐标 ", .Center(0), .Center(1)<br/> <br/> 'Document Application 文件的应用<br/> Set currDoc = ArcAa.Document<br/> Debug.Print "当前文件名 ", currDoc.Name<br/> <br/> Debug.Print "弧终点角 ", .EndAngle<br/> Debug.Print "弧半径 ", .Radius<br/> <br/> Debug.Print "弧起始角 ", .StartAngle<br/> Debug.Print "弧起始点 ", .startPoint(0), .startPoint(1)<br/> Debug.Print "厚度 ", .Thickness<br/> Debug.Print "弧度全角 ", .TotalAngle<br/> Debug.Print "可见性 ", .Visible<br/> End With<br/> Next ArcAa<br/>End Sub<br/>Result</p><p>.ArcLength 弧弦长 439.358687352826 <br/>.Area 弧面积 29906.7041554042 <br/>中心点坐标 391.358527961075 161.918314152521 <br/>当前文件名 Drawing1.dwg<br/>弧终点角 3.52706126334714 <br/>弧半径 166.320079604921 <br/>弧起始角 .885415778349277 <br/>弧起始点 496.63376116676 290.679698710454 <br/>厚度 0 <br/>弧度全角 2.64164548499787 <br/>可见性 True</p> <p>Sub Circle_Attribute()<br/> Dim cc As AcadCircle<br/> Dim currDoc As AcadDocument<br/> <br/> For Each cc In ThisDrawing.ModelSpace<br/> With cc<br/> Debug.Print "面积 ", .Area<br/> Debug.Print "中心点坐标 ", .Center(0), .Center(1)<br/> <br/> 'Document Application 文件的应用<br/> Set currDoc = cc.Document<br/> Debug.Print "当前文件名 ", currDoc.Name<br/> <br/> Debug.Print "圆周长 ", .Circumference<br/> Debug.Print "圆半径 ", .Radius<br/> Debug.Print "圆直径 ", .Diameter<br/> Debug.Print<br/> End With<br/> Next cc<br/>End Sub</p><p>Result</p><p>面积 127565.935202348 <br/>中心点坐标 295.296834613511 153.686624345957 <br/>当前文件名 Drawing1.dwg<br/>圆周长 1266.11248296509 <br/>圆半径 201.508060174248 <br/>圆直径 403.016120348496 </p><p><br/></p>
页:
[1]