
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
We are working on a lisp that will fill in some DWGPROPS with one key command. We have it working so typing the command "Approve" will fill in the Author, Subject, and Keyword of the DWGPROPS. For us the Keyword is the date the command is executed. What we can't get is the format of the date within this lisp to be MM/DD/YYYY. We have seen several forum posts for formatting the date, but have been unsuccessful in adding it to this lisp to get it functioning properly. Any help would be greatly appreciated.
Lisp is:
(defun C:APPROVE (/ App Doc DwgProps)
(setq App (vlax-Get-Acad-Object)
Doc (vla-Get-ActiveDocument App)
DwgProps (vla-Get-SummaryInfo Doc)
)
(vla-Put-Author DwgProps "COMPANY")
(vla-Put-Subject DwgProps "APPROVED FOR CONSTRUCTION")
(vla-Put-Keywords DwgProps (rtos (getvar 'cdate) 2 0))
(princ (vla-Get-Author DwgProps))(princ", ")
(princ (vla-Get-Subject DwgProps))(princ", ")
(princ (vla-Get-Keywords DwgProps))(princ", ")
(princ (vla-Get-RevisionNumber DwgProps))(princ", ")
(princ (vla-Get-Title DwgProps))(princ", ")
(princ (vla-Get-Comments DwgProps))(princ", ")
(princ)
)
Solved! Go to Solution.