Nick Schuckert
Usenet Archive
- Joined
- Dec 16, 2003
- Messages
- 2
- Reaction score
- 0
I want to use the SetCustomByIndex and SetCustomByKey ActiveX Methods to write Custom Property Names and Values to the AutoCAD 2004 Drawing Property Sheet. Would someone please post a Visual Lisp example that shows the syntax of these two methods.
Based on my AutoCAD 2004 Drawing Properties investigation, I have not found many examples on this topic. Here is what I have compiled thus far. Hope it's of value...
(vl-load-com)
(setq acadObject (vlax-get-acad-object))
(setq acadDocument (vla-get-ActiveDocument acadObject)) (setq DWGPROPS (vlax-get-Property acadDocument 'SummaryInfo)) ; ; Write Summary Info... ; (vlax-put-Property DWGPROPS 'Title "Some Title") (vlax-put-Property DWGPROPS 'Subject "Some Subject") (vlax-put-Property DWGPROPS 'Author "Some Author") (vlax-put-Property DWGPROPS 'Keywords "Some Keywords") (vlax-put-Property DWGPROPS 'Comments "Some Comments") (vlax-put-Property DWGPROPS 'HyperlinkBase "Some Hyperlink") (vlax-put-Property DWGPROPS 'LastSavedBy "Some Name") (vlax-put-Property DWGPROPS 'RevisionNumber "1") ; ; Write Custom Info... ; (vla-addCustomInfo DWGPROPS "Some Name" "Some Value")
Thanks In Advance!
Based on my AutoCAD 2004 Drawing Properties investigation, I have not found many examples on this topic. Here is what I have compiled thus far. Hope it's of value...
(vl-load-com)
(setq acadObject (vlax-get-acad-object))
(setq acadDocument (vla-get-ActiveDocument acadObject)) (setq DWGPROPS (vlax-get-Property acadDocument 'SummaryInfo)) ; ; Write Summary Info... ; (vlax-put-Property DWGPROPS 'Title "Some Title") (vlax-put-Property DWGPROPS 'Subject "Some Subject") (vlax-put-Property DWGPROPS 'Author "Some Author") (vlax-put-Property DWGPROPS 'Keywords "Some Keywords") (vlax-put-Property DWGPROPS 'Comments "Some Comments") (vlax-put-Property DWGPROPS 'HyperlinkBase "Some Hyperlink") (vlax-put-Property DWGPROPS 'LastSavedBy "Some Name") (vlax-put-Property DWGPROPS 'RevisionNumber "1") ; ; Write Custom Info... ; (vla-addCustomInfo DWGPROPS "Some Name" "Some Value")
Thanks In Advance!