Jump to content

how can i make 2 commands happen with one click of a toolbar button??


MikeP

Recommended Posts

i need to change the macro in the CUI so that when i click on a button in the toolbar it runs a command prior to the command i want to call up.

Link to comment
Share on other sites

You could call the command and add a line of pauses until the next command, in LISP it looks like this:

 

(command....)
(while (> (getvar "cmdactive") 0) (command pause))
(command....)

Link to comment
Share on other sites

Macro is where I first started in customizing commands, then I moved up to working in LISP (which I am still having a hard time working with). I created several custom macro's that contained over 10 commands in a single button click!

 

What commands are you wanting to combine? First, create a new command or copy the command that will be first in your macro. Set up the macro for the first command to do what you want, then at the end, put in ";" which acts like when you type enter which ends the first command, then ^C^C and the name of the second command you want.

 

Afterwards, you can create a custom icon or button image for your custom macro. Just remember, you never want to mess with the original macro commands, just copy and manipulate it that way.

 

***EDIT***

I forgot, when you have more than one command in a macro, if you choose to do it that way, use "+" after the last ";" and before ^C^C. Here is an example:

 

^C^Cselect;\pedit;m;previous;;j;j;a;12";+^C^Cfillet;p;last;

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...