Visual LISP, AutoLISP and General Customization

Visual LISP, AutoLISP and General Customization

Reply
Contributor
19 Posts
0 Kudos
Registered: ‎03-10-2010
Post 1 of 6

macro to open third party program from toolbar button

341 Views, 5 Replies
02-07-2012 06:40 AM

Hello -

 

I'm trying to create a macro for a toolbar button to open a third party program.

 

Basically we want to open a custom .exe application from a button on the ACAD toolbar.

 

Does anyone have a sample to share or tips\advice?

 

thank you!

Mentor
153 Posts
33 Kudos
Registered: ‎02-06-2007
Post 2 of 6

Re: macro to open third party program from toolbar button

02-07-2012 07:43 AM in reply to: mattholmes6282

I use (startapp "C:/Program Files/... /file.exe") as a macro assigned to a button.

But it can be a more elaborate lisp routine i.e. checking if the program exist or open a particular file.

 

Contributor
19 Posts
0 Kudos
Registered: ‎03-10-2010
Post 3 of 6

Re: macro to open third party program from toolbar button

02-07-2012 07:58 AM in reply to: phanaem

 

i tried this...

 

C^C^(startapp "C:\Program Files\Packages\INV PARTS.exe")

 

but it doesn't execute at all

 

it hangs at space after startapp

 

 

Mentor
153 Posts
33 Kudos
Registered: ‎02-06-2007
Post 4 of 6

Re: macro to open third party program from toolbar button

02-07-2012 08:07 AM in reply to: mattholmes6282

Use double backslah in path description

C^C^(startapp "C:\\Program Files\\Packages\\INV PARTS.exe")

or

C^C^(startapp "C:/Program Files/Packages/INV PARTS.exe")

Contributor
19 Posts
0 Kudos
Registered: ‎03-10-2010
Post 5 of 6

Re: macro to open third party program from toolbar button

02-07-2012 08:29 AM in reply to: phanaem

the forward slash allowed the entire path to be read however it came back as "nil"

 

(thanks for your help! i really appreciate the assistance)

 

i'm going to try linking it to another application other than the custom programmed app

Contributor
19 Posts
0 Kudos
Registered: ‎03-10-2010
Post 6 of 6

Re: macro to open third party program from toolbar button

02-07-2012 08:35 AM in reply to: mattholmes6282

ok... the path with the forward slash defintely works. I created a button to open Excel successfully.

 

The custom third party application we're using is a remote app that has a .rdp extension rather than a .exe

 

soooo i'm going to have to experiment more I guess.

Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Are you interested in helping shape the future of the Autodesk Community? To participate in this brief usability study, please click here. Your time and input is greatly appreciated!