Change Sheet Metal Unfold Rule with ILogic

Change Sheet Metal Unfold Rule with ILogic

philip1009
Advisor Advisor
2,490 Views
3 Replies
Message 1 of 4

Change Sheet Metal Unfold Rule with ILogic

philip1009
Advisor
Advisor

I have a sheet metal part that has set Sheet Metal Rules and Unfold Rules in Sheet Metal Defaults.  And I have the working code to change the active sheet metal rule via "SheetMetal.SetActiveStyle" working just fine.

 

SyntaxEditor Code Snippet

If SYSTEM="AC-10C" Or
SYSTEM="AC-20C-A" Or
SYSTEM="AC-20C-B" Or
SYSTEM="AC-20C-C" Then
SheetMetal.SetActiveStyle("4MM COMPOSITE")
ElseIf SYSTEM="AC-10P-A" Or
SYSTEM="AC-10P-B" Or
SYSTEM="AC-10P-C" Or
SYSTEM="AC-20P-A" Or
SYSTEM="AC-20P-B" Or
SYSTEM="AC-20P-C" Then
SheetMetal.SetActiveStyle(".125 ALUMINUM")
ElseIf SYSTEM="AC-10ST-A" Or
SYSTEM="AC-10ST-B" Or
SYSTEM="AC-10ST-C" Or
SYSTEM="AC-20ST-A" Or
SYSTEM="AC-20ST-B" Or
SYSTEM="AC-20ST-C" Then
SheetMetal.SetActiveStyle("14 GA. STEEL")
End If

 

But I can't find the code to change the Unfold Rule along with it.  Each Sheet Metal Rule has its own matching Unfold Rule with its own custom equations.

I know you can set the Unfold Rule under the Sheet tab of the Sheet Metal Rule, but how do you automatically make that rule the default unfold rule in the various part features.

 

Thanks in advance.

 

This is Inventor Professional 2017 btw.

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

HermJan.Otterman
Advisor
Advisor

Hello Philip

 

what do you mean by "various part features"

 

in your sheetmetal template you can setup your defaults, after creating the Sheetmetal rule and unfold rule.

 

if you would like to have different unfold rule, create more sheetmetalrules with matching unfold rules. 

If this answers your question then please select "Accept as Solution"
Kudo's are also appreciated Smiley Wink

Succes on your project, and have a nice day

Herm Jan


0 Likes
Message 3 of 4

philip1009
Advisor
Advisor

Hi Herm, I know you can set a default unfold rule in each sheet metal style.  But changing the sheet metal style doesn't change the unfold rule with it.  What I mean by various features is flanges, contour flanges, etc.  They don't take the unfold rule in the selected sheet metal style, they take the unfold rule selected from the drop-down in the sheet metal defaults.

 

Basically, If I want .125 ALUMINUM that already has the corresponding unfold rule in the style, it doesn't automatically change the default unfold rule in the flanges, etc. to.125 ALUMINUM, it always uses the unfold rule selected outside the sheet metal style.

 

I attached some pictures to try to show you what's going on.

 

Thanks for your quick reply.

0 Likes
Message 4 of 4

HermJan.Otterman
Advisor
Advisor
Accepted solution

Hello Philip,

 

if you set it up correctly, the sheetmetal unfold will change with the selection of the Sheetmetal rule.

 

I made a screencast:  http://autode.sk/2mQTk7C

 

at first, the unfold and material will not change.

after changing the settings in my Sheetmetal template, they will change with the sheetmetal rule

 

If this answers your question then please select "Accept as Solution"
Kudo's are also appreciated Smiley Wink

Succes on your project, and have a nice day

Herm Jan