Vla-get-ownerid
- 構文
- (vla-get-ownerid vla-object)
- 機能
- オーナー(親)オブジェクトのオブジェクト ID を取得する。
- 引数
-
- vla-object … VLAオブジェクト(すべての図形オブジェクト、AttributeReference、Block、Blocks、Dictionary、Dictionaries、Dimension、DimStyle、DimStyles、Group、Groups、Layer、Layers、Layout、Layouts、Linetype、Linetypes、Material、Materials、MLeaderStyle、ModelSpace、PaperSpace、PlotConfiguration、PlotConfigurations、RegisteredApplication、RegisteredApplications、SectionManager、SectionSettings、SortentsTable、TableStyle、TextStyle、TextStyles、UCS、UCSs、View、Views、Viewport、Viewports、XRecord)
- 戻り値
- オブジェクトのオーナーのオブジェクト ID。
- サンプル
(vl-load-com)
(defun c:Example_OwnerID()
;; マルチテキストを作成してそれのオーナーIDを返すサンプル
(setq acadObj (vlax-get-acad-object))
(setq doc (vla-get-ActiveDocument acadObj))
(setq corner (vlax-3d-point 0 10 0)
width 10
text "This is the text string for the MText object")
;; マルチテキストを作成
(setq modelSpace (vla-get-ModelSpace doc))
(setq MTextObj (vla-AddMText modelSpace corner width text))
(vla-ZoomAll acadObj)
(alert (strcat "マルチテキストの OwnerID は : " (itoa (vla-get-OwnerID MTextObj))))
)
関連事項