Message 1 of 8
Autoload Commands

Not applicable
08-23-2006
06:49 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi,
I need to create a few new commands for AutoCad 2007 in VB.NET and also make an installation package that adds them to a new toolbar on machines with AutoCAD 2007 already installed.
I am not too clear on how to make the toolbar and commands available as soon as the installation package has finished.
From what I have read on the forums, there are two ways of doing this.
1 - From within the installation package add keys to the registry like so..
HKLM\Software\Autodesk\AutoCAD\R17.0\ACAD-5001:409\Applications
\myApp
"DESCRIPTION"="myApp"
"LOADER"="C:\\wherever\\myApp .dll"
"LOADCTRLS"=dword:00000002
"MANAGED"=dword:00000001
SubKey:< br>myApp\Commands
"StartmyApp"="StartmyApp"
(As seen in http://discussion.autodesk.com/thread.jspa?messageID=4531456)
2 - Create a shortcut that forces acad.exe to run with the argument /b somescriptfile.scr, and in that script file include the line:
(command "netload" "C:\\wherever\\myCommands.dll")
I am new to AutoCAD programming, but somehow, neither of these two ways seem ideal, so my question is, Is there a better way of doing it ?
Is there are script file that AutoCAD always executes by default where I could put the "(command "netload"..etc" line and taht way save me from having to create the shorcut and script file ?
Thanks in advance,
Julian
I need to create a few new commands for AutoCad 2007 in VB.NET and also make an installation package that adds them to a new toolbar on machines with AutoCAD 2007 already installed.
I am not too clear on how to make the toolbar and commands available as soon as the installation package has finished.
From what I have read on the forums, there are two ways of doing this.
1 - From within the installation package add keys to the registry like so..
HKLM\Software\Autodesk\AutoCAD\R17.0\ACAD-5001:409\Applications
\myApp
"DESCRIPTION"="myApp"
"LOADER"="C:\\wherever\\myApp .dll"
"LOADCTRLS"=dword:00000002
"MANAGED"=dword:00000001
SubKey:< br>myApp\Commands
"StartmyApp"="StartmyApp"
(As seen in http://discussion.autodesk.com/thread.jspa?messageID=4531456)
2 - Create a shortcut that forces acad.exe to run with the argument /b somescriptfile.scr, and in that script file include the line:
(command "netload" "C:\\wherever\\myCommands.dll")
I am new to AutoCAD programming, but somehow, neither of these two ways seem ideal, so my question is, Is there a better way of doing it ?
Is there are script file that AutoCAD always executes by default where I could put the "(command "netload"..etc" line and taht way save me from having to create the shorcut and script file ?
Thanks in advance,
Julian