Message 1 of 7
How can I load a VBA project automatically when AutoCAD is launched
Not applicable
10-08-2003
03:32 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I need to automatically load and run a VBA project when AutoCAD is launched. The following method did not work:
----
Any project other than the default, acad.dvb, can be used by explicitly loading that project at startup using the VBALOAD command. The following code sample uses the AutoLISP startup file to load VBA and a VBA project named myproj.dvb when AutoCAD is started. Start notepad.exe and create (or append to) acad.lsp the following lines:
(defun S::STARTUP()
(command "_VBALOAD" "myproj.dvb")
)
----
I don't have acad.lsp file. I created this file and save it under 'C:\Program Files\AutoCAD2004' folder. But when I started the AutoCAD it did not load the VBA project! Could someone help please?
----
Any project other than the default, acad.dvb, can be used by explicitly loading that project at startup using the VBALOAD command. The following code sample uses the AutoLISP startup file to load VBA and a VBA project named myproj.dvb when AutoCAD is started. Start notepad.exe and create (or append to) acad.lsp the following lines:
(defun S::STARTUP()
(command "_VBALOAD" "myproj.dvb")
)
----
I don't have acad.lsp file. I created this file and save it under 'C:\Program Files\AutoCAD2004' folder. But when I started the AutoCAD it did not load the VBA project! Could someone help please?