ShaggyPE
Mechanical
- Sep 8, 2003
- 1,127
First off, I am not familiar with API or macros.
Getting that off my chest;
Ultimately I would like a macro that will add a custom property to all the files in a directory (the directory will only have parts and assemblies). I would also like the macro to supply the value for that property. I want the value to be the model file name. This task seems relatively simple from a programming perspective, and probably is in the hands of someone familiar with macros in general. Unfortunately I am not.
I have searched previous threads and the web. The macros that seem to offer a good starting point are FixProperties and PropertyEditorSpec from Lenny Kikstra.
I haven't had any success getting the FixProperties macro to work, however from its description, it will do the global creation of the property. Has anyone used/modified this macro?
Once I get the FixProperties macro to work, does anyone have any input on how to link the model file name to the property. It cannot be done solely through the solidworks interface. I hoped it would be listed in the "link to value" drop down, but that is only for mass properties.
Thanks in advance,
Shaggy
Getting that off my chest;
Ultimately I would like a macro that will add a custom property to all the files in a directory (the directory will only have parts and assemblies). I would also like the macro to supply the value for that property. I want the value to be the model file name. This task seems relatively simple from a programming perspective, and probably is in the hands of someone familiar with macros in general. Unfortunately I am not.
I have searched previous threads and the web. The macros that seem to offer a good starting point are FixProperties and PropertyEditorSpec from Lenny Kikstra.
I haven't had any success getting the FixProperties macro to work, however from its description, it will do the global creation of the property. Has anyone used/modified this macro?
Once I get the FixProperties macro to work, does anyone have any input on how to link the model file name to the property. It cannot be done solely through the solidworks interface. I hoped it would be listed in the "link to value" drop down, but that is only for mass properties.
Thanks in advance,
Shaggy