Here's some code I used to delete some custom properties with. It has a procedure for displaying a file tree window that I used in an Excel macro. This one recurses subdirectories, you have to comment out four lines near the bottom if you wish to perform your functions on files found ONLY in the...
MacPT,
I used the code from netshop21 and it works fine. Your Excel macro sounds interesting though... You are not inserting a Design Table, correct? Do you have a spreadsheet I can look at?
Thanks TheTick. I figured that out shortly after sending my last reply. Your code will give me a starting point and I'll play around with it tomorrow. If I can get it to work, it will add a custom property called "Weight", text type, with a value showing "SW-Mass@<FileName>".
Now I get a "Sub or function not defined" for "TargetConfigNames" in the following line of code:
TargetConfig = CStr(TargetConfigNames(cboTgtCfgs.ListIndex))
Thanks for the quick response, and this code appears to be exactly what I'm looking for. However, I'm getting a compile error; "User-defined type not defined" on line "Dim PropList() As swPropParams"
Does someone have the code to add a custom property, such as weight, and link it to the mass value in mass properties?
I have code to "GetMassProperties()" and display the mass value in a window or report, but I don't want to add a property and just paste the value. I would like to...
I'm having trouble setting the ambient color code for Directional2 in a macro. The color code I want is 12615808 (Red 128, Grn 128, Blu 192). The macro that folows works but does not change the Directional2 ambient color. Any help?
Code:
'Clr-DyeBlack.swb - 08/13/03 by [Me]
'
'Changes the part...
Yes, I have a part file open and visible. The macro will work if I first select the DT by clicking on it once with the mouse, otherwise it just runs without deleting the DT or returns the error that LoveAeris mentioned. I'm hoping to find the code that will do the same thing as clicking on the...
TheTick,
Thanks for the fast response. The code still doesn't select the DT though, so the macro just runs through and ends without deleting the DT. - Oorah
Hello,
How do I delete a Design Table from a part file within a macro? The recored code for this is listed below. This code will not work unless the DT is actually selected before running the macro. The boolean status line doesn't really select the DT. The real question then is "How do I...