Message 1 of 4
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello Autodeskers,
I got problem with my iLogic rule. This rule is in my template (attached) and it should check Sheet metal changes and if Flat pattern of this sheet metal is bigger than size that I will enter on the creation, then message should PopUp. But it will also color my part to Red > Even when the Inventor color says Default, not red. So where do I have mistake?
Thx
CODE:
InventorVb.DocumentUpdate() iProperties.Value("Custom","X") = MaxOfMany(SheetMetal.FlatExtentsLength, SheetMetal.FlatExtentsWidth) iProperties.Value("Custom","Y") = MinOfMany(SheetMetal.FlatExtentsLength, SheetMetal.FlatExtentsWidth) If iProperties.Value("Custom","X") > iProperties.Value("Custom","MEZ_X") Or iProperties.Value("Custom","Y") > iProperties.Value("Custom","MEZ_Y") Then MessageBox.Show("Sheet metal is too big!" & vbLf & "Max dimensions are: " & iProperties.Value("Custom","MEZ_X") & " x " & iProperties.Value("Custom","MEZ_Y") & vbLf & "Your dimensions of flat pattern are: " & iProperties.Value("Custom","X") & " x " & iProperties.Value("Custom","Y"), "ERROR!",MessageBoxButtons.OK,MessageBoxIcon.Error) Else MessageBox.Show("It's OK Your flat pattern dimensions are: " & iProperties.Value("Custom","X") & " x " & iProperties.Value("Custom","Y"), "OK") End If
Solved! Go to Solution.