AutoCAD and "Page Setup Import" Revisited
Contents:
Overview ---- Body
---- Conclusion
1Overview | |
The
Problem Years ago I wrote an article on how to use the "psetupin" command to make the process of importing Page Setups much easier for both users and CAD managers but then, somewhere along the way, Autodesk changed things and my trick stopped working. In this article I will review why Page Setup Importing is incredibly valuable and the trick I discovered to get my old routine to work again. For firms that have a lot of sheet sizes to deal with, including imperial and metric versions, numerous printing devices and incessant changes to any of these factors, Page Setups can be a CAD managers salvation. As a former CAD manager and now a CAD consultant, one of the things I figured out the hard way was to drive as much of the customization from single source points as possible. Page Setups, for example, can be stored in one or more unique template files that all users pull from whenever they need to configure or print a sheet. When a printing device is changed or added to the office network, a CAD manager won't have to modify all of the sheet template files. In the illustration to the right I show the default approach to importing one or more Page Setups. On the Page Setup Manager dialog box the Import... button simply takes a user to a generic Documents folder. If you use a template file to store Page Setups, the user may be able to pick on "Template (*.dwt)" as a File Type but most users are likely to give up at the Documents folder. The problem, therefore, is to make the process of Importing one or more Page Setups so simple that users will actually do it. |
|
2Body | |
The Solution If you read my first article on this subject, you will notice that I introduced the "psetupin" command as a solution for the problem described above. The trick was to use the dash ("-") in order to invoke the non-dialog version of "psetupin". The problem with that trick now is that the dash is completely ignored and thus the command always invokes the dialog box. This means that you cannot preset the Page Setup filename and location as you once could. In an obscure location in the AutoCAD Help menu under "Special Control Characters in Macros", you will find definitions for macro codes such as ";" for enter, "\" for pause and "^R" for turning off command versioning. For the latter character, the idea is that you can still get a macro to work as it did in an older release as long as you use "^R" in front of the macro string. If you pull up your Tool Palette and drop in a blank Command Tool, you can quickly program it to deliver a user right to a Page Setup template file as illustrated below right. The command string needs to read as follows: ^C^Cfiledia;0;^Rpsetupin;"Drive Letter:/Drive Folder(s)/File Name.dwt";filedia;1 The first part of this macro turns off the dialog functionality in AutoCAD to the "psetupin" command will just read the file location and name from the macro statement. Then, because no one wants to work without dialog boxes in AutoCAD, the macro turns the dialog functionality back on. When you specify the drive letter, probably a mapped network drive, and the path to the filename (.dwg or .dwt), make sure to use forward slashes ("/") since "\" are interpreted as pauses. |
|
3Conclusion | |
The End I also discovered that you can use this trick with the "^R" macro character to import Layouts. The Tool button code would read as follows: ^C^C^RLayout;"Drive Letter:/Drive Folder(s)/File Name.dwt"; For Importing Layouts, you don't need to deal with switching the filedia setting on and off because the Layout command doesn't have the weird quirk that the "psetupin" command has. |
© Copyright 2010 ARCHIdigm. All rights reserved.
Disclaimer and Copyright
Information