Community Tip - You can change your system assigned username to something more personal in your community settings. X
Hello All,
I am working on a Customization project to calculate the Scrap percentage of a sheet metal part and Listing all features. But i am not able to pull the total length and width of the part after flat pattern operation automatically.
I am able to pull the thickness of the part from CREO but is there any way i can get the total length and width of the part after flat pattern.
Note :
When i am creating a new sheet metal part in CREO-3.0 after doing Flat Pattern. I saw that 2 Restricted Parameters are getting created which is listing the Total length & width. Is it possible to pull these 2 values.
Using the option Flat Pattern Preview i am able to see the values but i cant get hold on to those.
Any Suggestion will be very helpful.
Solved! Go to Solution.
For older models I'd look at IpfcSolid.GeomOutline() or IpfcSolid.EvalOutline() methods where IpfcSolid refers to the flat state of the part (or the flat patern instance if is available).
Either of those functions will give you an array of 2 points representing the extremities of the part. The EvalOutline method has the option to ignore non-geometric features (points, curves, etc).
The flat pattern parameters (SMT_FLAT_PATTERN_WIDTH and SMT_FLAT_PATTERN_LENGTH) are feature parameters. What that means is that the "owner" of the parameter is the flat pattern feature.
For VB-API you can use IpfcSolid.GetFeatureById() or IpfcSolid.GetFeatureByName() to get the feature handle.
Next you use IpfcParameterOwner.GetParam() to get the parameter handle. This method takes as input the parameter name. From here you can get the value of the parameter as a double precision number.
Hi Gabrial,
Thanks for the reply. What ever you told i already tried it up and its working perfetly for a new sheet metal part which i am creating in CREO-3.0.
But the problem what i am facing is. I have many sheet metal items which is too old there if i am trying to acess this parameter i am not getting proper value its always showing 0.0
Please see the attached image's?
Newly created part .
Old Model.
For older models I'd look at IpfcSolid.GeomOutline() or IpfcSolid.EvalOutline() methods where IpfcSolid refers to the flat state of the part (or the flat patern instance if is available).
Either of those functions will give you an array of 2 points representing the extremities of the part. The EvalOutline method has the option to ignore non-geometric features (points, curves, etc).