Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations cowski on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

API Evaluating SW-Mass@Filename 1

Status
Not open for further replies.

farful

Mechanical
Mar 27, 2007
6
I currently have a macro to extract information from a part into an Excel file, such as its description and weight. I'm using the following:

ModelDoc.CustomInfo2(Configuration.Name, "Description")
ModelDoc.CustomInfo2(Configuration.Name, "Weight")

However, I'm having a problem with the weight. Instead of getting the evaluated value of the weight, I get the text string of "SW-Mass@@Configuration Name@Document Title". How can I get the numerical value of the weight instead of the text string?
 
Replies continue below

Recommended for you

farful,

If you are using SW2007 you want call CustomPropertyManager.Get2 (you will need to get the CustomPropertyManger object first). For SW2006 and SW2005 use ModleDoc2.GetCustomInofValue.

Note that in SW2007 ModelDoc2.CustomInfo2 is obsolete.

SA
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor