Looking for a command to get the actual area of the flat pattern similar to SheetMetal.FlatExtentsArea...
I don't think there is anything built into iLogic for this, but you can use the API to do it. Here is a quick example.
I hope this helps.
Best of luck to you in all of your Inventor pursuits,
Curtis
http://inventortrenches.blogspot.com
Dim oDoc As PartDocument oDoc = ThisApplication.ActiveDocument Try Dim oDef As SheetMetalComponentDefinition oDef = oDoc.ComponentDefinition Dim oFlatPattern As FlatPattern oFlatPattern = oDef.FlatPattern oArea = Round(oFlatPattern.TopFace.Evaluator.Area,3) MessageBox.Show("Flat pattern area: " & oArea & " cm^2", "iLogic") Catch MessageBox.Show("Error: Verify that a flat pattern exists", "iLogic") End Try
Something kind of cool I stumbled across a while ago - if you add a line of code that references the flat pattern extents, such as shown below, then iLogic will just create the flat pattern for you instead of causing an error. You don't actually have to use the extents for anything - simply referencing one of them is enough.
This would let you pull out the Try / Catch error handling, and instead makes Inventor just fix it for you if the flat pattern is missing.
X_Measure = SheetMetal.FlatExtentsLength
Can't find what you're looking for? Ask the community or share your knowledge.