Hi all,
I have created two iParts, both with cooresponding tables which I then put into an iAssembly so I can change the size of a padeye and two cheek plates depending upon the desired Working Load Limit. I have a very basic form right now with a drop down menu to chose the different Safe Working Loads but whichever one I choose, is not changing the table configuration to the desired size. Clearly my iLogic code is not working the way I would like. See below and also see attached screen shots so you know what I am working with.
If Parameter("SWL") = "4.75Te" Then
iPart.ChangeRow("PADEYE iPART - IMPERIAL:1", "WLL = 4.75Te")
iPart.ChangeRow("CHEEK PLATE iPART:1", "WLL = 4.75Te")
iPart.ChangeRow("CHEEK PLATE iPART:2", "WLL = 4.75Te")
ElseIf Parameter("SWL") = "6.5Te" Then
iPart.ChangeRow("PADEYE iPART - IMPERIAL:1", "WLL = 6.5Te")
iPart.ChangeRow("CHEEK PLATE iPART:1", "WLL = 6.5Te")
iPart.ChangeRow("CHEEK PLATE iPART:2", "WLL = 6.5Te")
ElseIf Parameter("SWL") = "8.5Te" Then
iPart.ChangeRow("PADEYE iPART - IMPERIAL:1", "WLL = 8.5Te")
iPart.ChangeRow("CHEEK PLATE iPART:1", "WLL = 8.5Te")
iPart.ChangeRow("CHEEK PLATE iPART:2", "WLL = 8.5Te")
ElseIf Parameter("SWL") = "9.5Te" Then
iPart.ChangeRow("PADEYE iPART - IMPERIAL:1", "WLL = 9.5Te")
iPart.ChangeRow("CHEEK PLATE iPART:1", "WLL = 9.5Te")
iPart.ChangeRow("CHEEK PLATE iPART:2", "WLL = 9.5Te")
ElseIf Parameter("SWL") = "12Te" Then
iPart.ChangeRow("PADEYE iPART - IMPERIAL:1", "WLL = 12Te")
iPart.ChangeRow("CHEEK PLATE iPART:1", "WLL = 12Te")
iPart.ChangeRow("CHEEK PLATE iPART:2", "WLL = 12Te")
ElseIf Parameter("SWL") = "13.5Te" Then
iPart.ChangeRow("PADEYE iPART - IMPERIAL:1", "WLL = 13.5Te")
iPart.ChangeRow("CHEEK PLATE iPART:1", "WLL = 13.5Te")
iPart.ChangeRow("CHEEK PLATE iPART:2", "WLL = 13.5Te")
ElseIf Parameter("SWL") = "17Te" Then
iPart.ChangeRow("PADEYE iPART - IMPERIAL:1", "WLL = 17Te")
iPart.ChangeRow("CHEEK PLATE iPART:1", "WLL = 17Te")
iPart.ChangeRow("CHEEK PLATE iPART:2", "WLL = 17Te")
ElseIf Parameter("SWL") = "25Te" Then
iPart.ChangeRow("PADEYE iPART - IMPERIAL:1", "WLL = 25Te")
iPart.ChangeRow("CHEEK PLATE iPART:1", "WLL = 25Te")
iPart.ChangeRow("CHEEK PLATE iPART:2", "WLL = 25Te")
ElseIf Parameter("SWL") = "35Te" Then
iPart.ChangeRow("PADEYE iPART - IMPERIAL:1", "WLL = 35Te")
iPart.ChangeRow("CHEEK PLATE iPART:1", "WLL = 35Te")
iPart.ChangeRow("CHEEK PLATE iPART:2", "WLL = 35Te")
Parameter.UpdateAfterChange = True
End If
This code was actually overwriting the table properties (in excel), so I know this is wrong, I just couldn't find any snippet for changing a table configuration and I have looked everywhere online but have had no luck at all finding anything like this. Any ideas?
I have also tried this
IfParameter("SWL")="6.5Te"ThenComponent.ReplaceiPart("PADEYE iPART - IMPERIAL:1", "WLL = 6.5Te", True, 1)Component.ReplaceiPart("CHEEK PLATE iPART:1", "CHEEK PLATE iPART-02", True, 1)Component.ReplaceiPart("CHEEK PLATE iPART:1", "CHEEK PLATE iPART-02", True, 1)Parameter.UpdateAfterChange=TrueEndIf
But it is somehow not even finding my "PADEYE iPART - IMPERIAL:1"
I noticed in the iAssembly, it shows these iParts as tables, and does not display the original iPart file name, but displays the "Member" from the table. I think this has something to do with it, I just can't figure this out..