Grigs Posted April 16, 2014 Share Posted April 16, 2014 Our template for AutoCAD has several page setups for various different sizes. I was looking into making button macros that would automate this. So basically there would be a button, say for 24"x36", that when pressed would automatically use the predefined pagesetup for 24"x36". Can anyone help me out? I'm not looking to do any error checking or importing of page layouts. Quote Link to comment Share on other sites More sharing options...
andy81 Posted April 16, 2014 Share Posted April 16, 2014 you can create a Custom Command and add it to a menu or toolbar. for my setup it looks like this: ^C^CDel_Pagesetups;^C^C.-PSETUPIN "//Some_Network_Location/Settings A1.dwg" "*" in the example above are some important parts to understand. ^C^CDel_Pagesetups; ~ this part initiates the command to delete current page setups (leave this out if you have no need of it) ^C^.-PSETUPIN "//Some_Network_Location/Settings A1.dwg ~ this part loads Pagesetups from a drawing file you have created as a template. in this template drawing you must have created the pagesetups "*" ~ this part tells it to load all of the pagesetups from the drawing "Settings A1.dwg" to make the custom command use the "create a new command" button seen below: once the custom command is created you can then drag the new command from the command list (the list found below the new custom command button) drag it from there up into the toolbar or menu you wish to add it to. Hit the apply button at the bottom of the Customize user Interface Dialog Box to apply this change to your model. Hope this helps Cheers, Andy. Quote Link to comment Share on other sites More sharing options...
Grigs Posted April 16, 2014 Author Share Posted April 16, 2014 Thanks for the reply Andy. The issue is I already have the page setups in the drawings. What I need is a button that will force a page setup when a tool button is pushed. Quote Link to comment Share on other sites More sharing options...
Grigs Posted April 16, 2014 Author Share Posted April 16, 2014 And for some reason I can't get the path to the template correct. I have tried "T://path/drawing.dwg", "//path/drawing.dwg", "T:\\path\drawing.dwg" but none work Quote Link to comment Share on other sites More sharing options...
andy81 Posted April 16, 2014 Share Posted April 16, 2014 If you use a mapped Drive such as T: then you will need to use the following format: ^C^CDel_Pagesetups;^C^C.-PSETUPIN "T:/network location/plot settings A1.dwg" "*" if you use UNC path names then you need to use: ^C^CDel_Pagesetups;^C^C.-PSETUPIN "//server name/path/more path/still more/Plot Settings A1.dwg" "*" UNC path names take away the requirement for mapping the "t:" drive correctly (from your example) does that work for you now? Andy. Quote Link to comment Share on other sites More sharing options...
Grigs Posted April 17, 2014 Author Share Posted April 17, 2014 The T: drive is our network drive. I modified the script and it works great. Now I just need to figure out how to force one of those page setups to paper space. Quote Link to comment Share on other sites More sharing options...
tzframpton Posted April 17, 2014 Share Posted April 17, 2014 Why not just have multiple templates? Quote Link to comment Share on other sites More sharing options...
Grigs Posted April 17, 2014 Author Share Posted April 17, 2014 That is an option. I chose to go with one template with multiple page setups mostly for ease and less cluttered. Most of the people I work with can't even bother to go into the page setup and choose a setup. So having multiple templates might confuse them even more. I have created a custom ribbon for all the stuff we use at our work. I figured placing some buttons that automated the page setup (just click the '22' button to setup a 22"x34" sheet) would hopefully make it easier. Quote Link to comment Share on other sites More sharing options...
Grigs Posted April 17, 2014 Author Share Posted April 17, 2014 Andy, the ^C^CDel_Pagesetups; doesn't seem to do anything Quote Link to comment Share on other sites More sharing options...
tzframpton Posted April 17, 2014 Share Posted April 17, 2014 So five templates will confuse people? Or having five Page Setups in one file will confuse people? I dunno, just seems like you could do what you're doing by having it fine tuned. This is how I've always done it. It can be confusing to have some "magic" custom button that is not a standard option in AutoCAD, too. And new hires... how will they know about that magic button unless someone shows them? Fine tune the templates and you're good to go in my book. Quote Link to comment Share on other sites More sharing options...
Grigs Posted April 17, 2014 Author Share Posted April 17, 2014 5 templates would confuse them. And sometimes we get into a project and have to change paper size. Then people would have to figure out that. To me it's just easier to have them all defined on one template. Also, it's easier to do a publish and import the page setups when they are all in one spot. And as for new hires, we have all this explained in our CAD manual. Quote Link to comment Share on other sites More sharing options...
tzframpton Posted April 17, 2014 Share Posted April 17, 2014 *shrugs* if you say so then. 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.