Can not access SheetMetalComponentDefinition if part is based on derived part

Can not access SheetMetalComponentDefinition if part is based on derived part

Skadborg.NTI
Advocate Advocate
799 Views
3 Replies
Message 1 of 4

Can not access SheetMetalComponentDefinition if part is based on derived part

Skadborg.NTI
Advocate
Advocate

I want to unfold a sheetmetal part. This works for at normal sheetmetalpart:

doc = ThisDoc.Document
Dim DocumentSubType = doc.SubType
If DocumentSubType =  "{9C464203-9BAE-11D3-8BAD-0060B0CE6BB4}" Then
    MessageBox.Show("This is a sheetmetal part")
    Dim smCompDef As Inventor.SheetMetalComponentDefinition
    smCompDef = doc.ComponentDefinition
    If (Not smCompDef.HasFlatPattern) Then
        smCompDef.Unfold
    End If
End If

But if I use a skeleton part, and derive that one into a sheetmetal part, then this new sheetmetal part apparently doesn't have a ComponentDefinition of type=SheetMetalComponentDefinition? Above code fails at the line

smCompDef = doc.ComponentDefinition

So this is ok:

Browser2.PNG

and this is doesn't work:

Browser.PNG

 

 

 

 

 

 

 

 

 

 

 

 

 

 

How do I get access to the sheetmetal definition of the last sample?

0 Likes
Accepted solutions (1)
800 Views
3 Replies
Replies (3)
Message 2 of 4

xiaodong_liang
Autodesk Support
Autodesk Support
Accepted solution

Hi,

 

I tested your dataset in Inventor 2016. It looks working well. The video is attached. Could you check anything I missed?

0 Likes
Message 3 of 4

Skadborg.NTI
Advocate
Advocate
Hi Xiaodong

It seems that my installation has been corrupted since I - just like you - couldn't reproduce the problem on an other computer. I reinstalled and now it works. Thanks for testing!
0 Likes
Message 4 of 4

llorden4
Collaborator
Collaborator

I too had this failure at the same location, using 2018.  A restart of Inventor resolved my issue, glad to see a re-install was not required in my case.

Autodesk Inventor Certified Professional
0 Likes