Reading Physical Properties

 

Hi..

I am updating the model, with Density behaving as variable , not as a physical property. It is working fine. But when model gets saved, I need to read the mass.  I don't know which method , I need to call.

previously, when Density was treated as physical property, I used to call ComputePhysicalProperties method. Please reply..

 

 

Posted by: Nudrat Hassan
Post date: 4/15/2009 1:58:43 AM

3 REPLIES

RE: Reading Physical Properties

Model.GetPhysicalProperties?

 

Posted by: Jason Newell
Post date: 4/17/2009 7:08:26 PM

RE: Reading Physical Properties

This is the piece of code I am writing :

Dim objBody As SolidEdgePart.Model = Nothing

objBody = objPart.Models.Item(1).Body

Call objBody.GetPhysicalProperties(set of parameters as required)

But its not working, its throwing following error

"Unable to cast COM object of type 'System.__ComObject' to interface type 'SolidEdgePart.Model'. This operation failed because the QueryInterface call on the COM component for the interface with IID '{49852F7F-A403-11CE-818E-0800363A1E02}' failed due to the following error: No such interface supported (Exception from HRESULT: 0x80004002 (E_NOINTERFACE))."

 

Posted by: Nudrat Hassan
Post date: 4/20/2009 8:52:13 PM

RE: Reading Physical Properties

 

Your code is wrong.  It should beSmiley Very Happyim objModel As SolidEdgePart.Model = Nothing objModel = objPart.Models.Item(1)Call objModel.GetPhysicalProperties(set of parameters as required)

 

Posted by: Jason Newell
Post date: 4/21/2009 7:56:01 AM