CAD得到ImageMark数据(com接口VB语言)
2020-12-13 01:44
标签:order pac cal index long eve aci raw syn CAD得到ImageMark数据(com接口VB语言) 标签:order pac cal index long eve aci raw syn 原文地址:https://www.cnblogs.com/yzy0224/p/11007973.html
Private Sub MxDrawX1_CustomEvent(ByVal sEventName As String)
If sEventName =
"ObjectGripEdit"
Then
Dim eventParam As MxDrawXLib.MxDrawResbuf
‘ 得到事件参数
Set eventParam = MxDrawX1.CustomEventParam
Dim lId As Long
‘
得到夹点被编辑的对象id
lId = eventParam.AtLong(0)
‘查看对象是否是ImageMark对象,并返回对象数据。
Dim data As MxDrawXLib.MxDrawResbuf
Set data = MxDrawX1.CallLongParam1("Mx_GetImageMarkData", lId)
If data.AtString(0) = "Ok" Then
‘
得到Mark对象的文件名.
MsgBox (data.AtString(1))
‘插入点x
MsgBox (data.AtDouble(2))
‘
插入点y
MsgBox (data.AtDouble(3))
‘缩放比例
data.AtDouble (4)
‘
图片在绘图时,是否参于打印,出图
data.AtLong (5)
‘否绘制它的在文档中的外框标记
data.AtLong (6)
‘
图片在数据库中的宽度
data.AtDouble (7)
‘图片在数据库中的高度
data.AtDouble (8)
‘
闪烁时使用的ImageFile
data.AtString (9)
‘标注文本
data.AtString (10)
‘
标注文本高度
data.AtDouble (11)
‘颜色索引
data.AtLong (12)
End If
End If
End Sub