AndyC Posted November 11, 2010 Share Posted November 11, 2010 I have two existing working macros that i would like to combine together to form one, but am struggling to work out how to combine them. The first insets a block at a defined scale and rotation into the drawing. The second insets an incremental number. CODE 1 ^c^c-layer;m;"LB-T007-SET-OUT";c;WHITE;;l;continuous;;;-insert;"LB-setting-out-point";sc;25;ro;0; CODE 2 ^c^c_text;\;;$M=$(+,$(getvar,USERR1),$(getvar,USERR2));setvar;USERR1;$M=$(+,$(getvar,USERR1),$(getvar,USERR2)); It would also be great if this command would then repeat for consectutive mouse clicks until the command chain is ended. What i want to end upwith is a command that inserts a block with an accompanying incremental ref number and to repeat this for number of repetitions Any assitance would be mush appreciated Andy C Quote Link to comment Share on other sites More sharing options...
ReMark Posted November 11, 2010 Share Posted November 11, 2010 Renderman: The OP is using LT. Haven't we seen this request in two other forms? It's deja' vue all over again. Quote Link to comment Share on other sites More sharing options...
BlackBox Posted November 11, 2010 Share Posted November 11, 2010 Renderman: The OP is using LT. ... Ohhhhh! I completely overlooked that! I'm still struggling to understand why anyone buys LT anymore. Haven't we seen this request in two other forms? I do not recall seeing this, otherwise I would have ignored the OP. Quote Link to comment Share on other sites More sharing options...
AndyC Posted November 11, 2010 Author Share Posted November 11, 2010 Unfortunately i am using Keyscape LT 2010 which is a Landscape Architecture package that runs on the back of AutoCAD LT and has had the LISP functions disabled. The only way i am able to do this as far as i am aware is via the CUI interface and creating a menu bar button against which i can assign a macro. I have done this indivudally for both codes but want to try and combine it together. Quote Link to comment Share on other sites More sharing options...
ReMark Posted November 11, 2010 Share Posted November 11, 2010 Here's one: http://www.cadtutor.net/forum/showthread.php?54236-HELP-with-a-non-working-Macro&highlight=macro And here's the other: http://www.cadtutor.net/forum/showthread.php?54236-HELP-with-a-non-working-Macro&highlight=incremental And this is where it all started: http://www.cadtutor.net/forum/showthread.php?54181-NEEDED-Deisel-Expression-for-incremental-numbering&highlight=macro So we now have four choices as where to respond. Take your pick. LOL Quote Link to comment Share on other sites More sharing options...
ReMark Posted November 11, 2010 Share Posted November 11, 2010 I think the OP just got a bit carried away by the lack of response. Rather than "bumping" the original post he repeated it in a slightly different fashion. The first attempt I can understand but the next two really weren't necessary in my opinion. But as the wife says, "It is what it is." I'm willing to give him the benefit of the doubt. Quote Link to comment Share on other sites More sharing options...
BlackBox Posted November 11, 2010 Share Posted November 11, 2010 I think the OP just got a bit carried away by the lack of response. Rather than "bumping" the original post he repeated it in a slightly different fashion. The first attempt I can understand but the next two really weren't necessary in my opinion. But as the wife says, "It is what it is." I'm willing to give him the benefit of the doubt. Fair enough, I'll follow your wise decision... in kind, I've deleted my post. Quote Link to comment Share on other sites More sharing options...
eldon Posted November 11, 2010 Share Posted November 11, 2010 Whilst not being a user of Macros, I have been idly browsing, and one bit of information that I gleaned was that there was a limit of the number of characters on each line. I don't know whether this is still the case, but you needed to put a "+" at the end of each line to join it on to the next line of code. Quote Link to comment Share on other sites More sharing options...
BlackBox Posted November 11, 2010 Share Posted November 11, 2010 Whilst not being a user of Macros, I have been idly browsing, and one bit of information that I gleaned was that there was a limit of the number of characters on each line. I don't know whether this is still the case, but you needed to put a "+" at the end of each line to join it on to the next line of code. If you're speaking in regard to the code in the OP, they are each on only a single line. They appear wrapped (on multiple lines) as a result of your browser windows size and/or screen resolution. Quote Link to comment Share on other sites More sharing options...
eldon Posted November 11, 2010 Share Posted November 11, 2010 I was hoping that it was the answer to his query, as the combined length of both macros comfortably exceeds 80 characters. Quote Link to comment Share on other sites More sharing options...
BlackBox Posted November 11, 2010 Share Posted November 11, 2010 I was hoping that it was the answer to his query, as the combined length of both macros comfortably exceeds 80 characters. I wasn't disagreeing with you, rather simply trying to clarify what I believe to be two separate topics. I will take your word, as I don't have the time to look up the character length criteria, for myself. Perhaps someone smarter than I will come along to confirm/deny. The OP could certainly 'trim the fat' from his macros, even if they were to remain two separate commands: For example, both of these have the same final result: ^c^c-layer;m;"LB-T007-SET-OUT";c;WHITE;;l;continuous;;;-insert;"LB-setting-out-point";sc;25;ro;0; ^C^C[color=red]^P._[/color]-layer;[color=red]_[/color]m[color=red]ake[/color];"LB-T007-SET-OUT"[color=red];;._[/color]-insert;"LB-setting-out-point";[color=red]_[/color]sc[color=red]ale[/color];25;[color=red]_[/color]ro[color=red]tate[/color];0; ... The latter example is also easier to maintain. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.