Visual LISP, AutoLISP and General Customization
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Special Control Characters in Selecting

2 REPLIES 2
Reply
Message 1 of 3
suicidedoors
777 Views, 2 Replies

Special Control Characters in Selecting

Hey Guys,

I am just getting into creating macros for AutoCAD, Im actually using Advance Steel but I am currently creating AutoCAD macros to start off with. So for a little personal exersise to get better I want to create a macro that will start with PEDIT, then MULTIPLE, then JOIN them. I can get this to work but it seems I have to dictate the number of clicks when selecting multiple polylines, I was wondering how I can select as many as I want from 2 to however many I want without it needing a specific amount. Here is the macro I have created so far and it does work with 4 clicks but it only works with 4.

^C^C^C_PEDIT;Multiple;\\\\;JOIN;;;\

2 REPLIES 2
Message 2 of 3
Kent1Cooper
in reply to: suicidedoors


@suicidedoors wrote:

.... a macro that will start with PEDIT, then MULTIPLE, then JOIN them. I can get this to work but it seems I have to dictate the number of clicks when selecting multiple polylines, I was wondering how I can select as many as I want ....


 

The trick to this sort of thing in a command macro is that the SELECT command can take any number  of selections and/or selection options [W, C, F, R, A, etc.] all under the supervision of one  backslash for User input.  So you use SELECT and one backslash, and then get into whatever command you want, and use Previous for the selection in it:

^C^C_.SELECT \_.PEDIT Multiple _Previous ;JOIN ;;

Kent Cooper, AIA
Message 3 of 3
Paul_Gander
in reply to: suicidedoors

Unfortunately the PEDIT command doesn't behave well in macros because of the way it handles object selection. The JOIN command will work better for you here.

 

For other options you could use something like:

 

^c^c_select;\_pedit;_multiple;_previous;;_width;25;;

 

(As already suggested by @Kent1Cooper) but this may not work if you have polylines preselected when calling the macro because it affects which options are displayed. Also, check the value of the PICKADD variable when using the SELECT command.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

AutoCAD Inside the Factory


Autodesk Design & Make Report