martan1912 Posted January 17, 2014 Share Posted January 17, 2014 (edited) Hello, I had 2 custom buttons on my toolbar for scaling certain objects between metric and imperial units, for some reason they don't work in version 2014. To scale to metric I have this macro: select;\scale;$M=$(if,$(=,$(getvar,pickfirst),0),previous;)\25.4 To scale to inches: select;\scale;$M=$(if,$(=,$(getvar,pickfirst),0),previous;)\0.03937007874015748031496062992126 Does it have to be rewritten ? It used to work just perfect for what I need it for. Thanks for help. Edited January 20, 2014 by SLW210 added code tags. Quote Link to comment Share on other sites More sharing options...
Tuns Posted January 17, 2014 Share Posted January 17, 2014 There is a space between the P and R in "Previous" and there is one more space after the semi colon behind the word "Previous". Quote Link to comment Share on other sites More sharing options...
martan1912 Posted January 17, 2014 Author Share Posted January 17, 2014 There is a space between the P and R in "Previous" and there is one more space after the semi colon behind the word "Previous". I know, that's how it got pasted into the message window, I don't know why, but it is typed in correctly in Autocad. As I mentioned, it worked just fine in other versions. Quote Link to comment Share on other sites More sharing options...
martan1912 Posted January 17, 2014 Author Share Posted January 17, 2014 When I click the button on any of them, all I get on the command line is Command: select Quote Link to comment Share on other sites More sharing options...
Tuns Posted January 17, 2014 Share Posted January 17, 2014 Is there a reason why you made them so complicated? You don't even need diesel for this. Quote Link to comment Share on other sites More sharing options...
martan1912 Posted January 17, 2014 Author Share Posted January 17, 2014 Honestly I haven't made them, I got them somewhere while back. If there is a simpler way to achieve the same, I'd appreciate your help. I just need this tool since I do a lot of CNC work and I have to use metric objects in my CAD, also going back and forth between units. It really helps with everyday work. Quote Link to comment Share on other sites More sharing options...
Tuns Posted January 17, 2014 Share Posted January 17, 2014 ^C^Cscale;\;\25.4; That is to go from standard to metric. To make it go from metric to standard just change the number at the end. I can adjust it a bit to fit your needs if you would like. Just let me know if you need me to add anything. If you add one more \ like so: ^C^Cscale;\\;\25.4; You can window objects... OR if you want to scale everything then this: ^C^Cscale;all;\25.4; Would be better. Quote Link to comment Share on other sites More sharing options...
martan1912 Posted January 17, 2014 Author Share Posted January 17, 2014 Thanks for your offer to help. Now , is this going to let me pick objects I want to scale first ? That's how it used to work. Click on the icon, select the objects and they got scaled. I don't want to scale all objects in the drawing, just some of them, per my selection. Quote Link to comment Share on other sites More sharing options...
martan1912 Posted January 17, 2014 Author Share Posted January 17, 2014 Sorry, should have red your post better, you said I can window objects. Let me test it, I'll get back to you. Quote Link to comment Share on other sites More sharing options...
martan1912 Posted January 17, 2014 Author Share Posted January 17, 2014 Perfect, thank you very much ! Quote Link to comment Share on other sites More sharing options...
SLW210 Posted January 20, 2014 Share Posted January 20, 2014 I know, that's how it got pasted into the message window, I don't know why, but it is typed in correctly in Autocad. As I mentioned, it worked just fine in other versions. That's why you need to use Code Tags for Code. Code posting guidelines Quote Link to comment Share on other sites More sharing options...
Tuns Posted January 20, 2014 Share Posted January 20, 2014 Perfect, thank you very much ! No problem. 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.