LoadDraftingStandard

August 12th, 2011


Imagine you received a set of SolidWorks drawings from an outside source. Unfortunately the people who created the drawings didn’t use your drafting standards. [The peasants!]

You may be tempted to create a little macro that goes through every one of your settings, one at a time, setting user preference toggles, integer values, blah, blah… Not a bad idea, but doing this is slow, tedious and you’ll run into some “undocumented issues” that my lawyers don’t want me to get into. So instead, open your drawing template and save your standards out as a file.

ExternalFile

Now in your API code, after you open the drawing, use the “Drawing.Extension.LoadDraftingStandard” method to load the standards file you created. This one line of code can then take place of the possible hundreds of lines of codes setting the preferences one at a time.

Jeff Sweeney

CSWE Engineering Data Specialist 3DVision Technologies

Tags: ,

Loading Facebook Comments ...

One Response to “LoadDraftingStandard”

  1. Randy Simmons says:

    Or if you don’t need to do hundreds of files, you can just open the “bad” drawing and go to the window you show and hit “LOAD FROM EXTERNAL FILE”, browse for your “good” standard and it will plow over the “bad” file and “fix” it.

Leave a Reply

Follow
Get every new post delivered to your inbox
Join other followers
Powered By WPFruits.com
Bear