Mike,
I'm still getting the timeout. I am compiling using .NET Framework 2.0 rather than 4.0 as you are.
I am pasting my Form Rule for you to see what I am doing wrong. I'm assuming the problem is here and not in the VB.
AddReference "WindowFrame2.dll"
Sub Main()
localTrigger = iTrigger0
Using dlg As New ClassLibrary1.Dialog1
dlg.W_Inside = W_Inside
dlg.H_Inside = H_Inside
dlg.Flange_Thickness = Flange_Thickness
dlg.Add_Flange_Left = Add_Flange_Left
dlg.Add_Flange_Right = Add_Flange_Right
dlg.Add_Flange_Top = Add_Flange_Top
dlg.Add_Flange_Bottom = Add_Flange_Bottom
dlg.X_Hole = X_Hole
dlg.Y_Hole = Y_Hole
dlg.M10_X_Qty = M10_X_Qty
dlg.Horiz_M8_Holes_Before_M10 = Horiz_M8_Holes_Before_M10
dlg.M10_Y_Qty = M10_Y_Qty
dlg.Vert_M8_Holes_Before_M10 = Vert_M8_Holes_Before_M10
dlg.User = iProperties.Value("Custom", "User")
dlg.DateCreated = iProperties.Value("Custom", "Created")
dlg.GBFamily = UCase(iProperties.Value("Summary","Subject"))
dlg.Stock1 =UCase(Left(iProperties.Value("Project","Stock Number"),5))
dlg.Stock2=UCase(Mid(iProperties.Value("Project","Stock Number"),7,3))
dlg.Stock3=UCase(Mid(iProperties.Value("Project","Stock Number"),11,2))
dlg.Stock4=UCase(Mid(iProperties.Value("Project","Stock Number"),14,3))
dlg.Stock5=UCase(Mid(iProperties.Value("Project","Stock Number"),18,1))
dlg.Stock6=UCase(Mid(iProperties.Value("Project","Stock Number"),20,5))
dlg.iLogicWakeup = AddressOf iLogicWakeup ' Connect our wakeup function to the dialog.
Dim i As Integer = dlg.ShowDialog()
if i <> vbOK then return
W_Inside = dlg.W_Inside
H_Inside = dlg.H_Inside
Flange_Thickness = dlg.Flange_Thickness
Add_Flange_Left = dlg.Add_Flange_Left
Add_Flange_Right = dlg.Add_Flange_Right
Add_Flange_Top = dlg.Add_Flange_Top
Add_Flange_Bottom = dlg.Add_Flange_Bottom
X_Hole = dlg.X_Hole
Y_Hole = dlg.Y_Hole
M10_X_Qty = dlg.M10_X_Qty
Horiz_M8_Holes_Before_M10 = dlg.Horiz_M8_Holes_Before_M10
M10_Y_Qty = dlg.M10_Y_Qty
Vert_M8_Holes_Before_M10 = dlg.Vert_M8_Holes_Before_M10
iProperties.Value("Custom","User") = dlg.User
iProperties.Value("Custom","Created")=dlg.DateCreated
iProperties.Value("Summary","Subject")=UCase(dlg.GBFamily)
iProperties.Value("Project","Stock Number") = UCase(dlg.Stock1 & " " & dlg.Stock2 & " " & dlg.Stock3 & " " & dlg.Stock4 & " " & dlg.Stock5 & " " & dlg.Stock6)
End Using
' Modifying model based on quantity of M10 holes
If M10_X_Qty = "2" Then
Feature.IsActive("M10x18 X Middle Hole") =False
Feature.Isactive("M10x18 Second X Tapped Hole") = False
Feature.Isactive("M10x18 Second X Hole Mirror") = False
Elseif M10_X_Qty = "3" Then
Feature.Isactive("M10x18 X Middle Hole") = True
Feature.Isactive("M10x18 Second X Tapped Hole") = False
Feature.Isactive("M10x18 Second X Hole Mirror") = False
Elseif M10_X_Qty = "4" Then
Horiz_M8_Holes_Between_1_2_M10_Holes= Inputbox("Enter number of M8 holes between the first and second M10 hole, starting at left, on top of the window frame","Horizontal M8 Holes Between First & Second M10 Holes","2")
Feature.Isactive("M10x18 X Middle Hole") = False
Feature.Isactive("M10x18 Second X Tapped Hole") = True
Feature.Isactive("M10x18 Second X Hole Mirror") = True
Else
Feature.IsActive("M10x18 X Middle Hole") =False
Feature.Isactive("M10x18 Second X Tapped Hole") = False
Feature.Isactive("M10x18 Second X Hole Mirror") = False
End if
if M10_Y_Qty = "2" Then
Feature.IsActive("M10x18 Y Middle Hole") =False
Feature.Isactive("M10x18 Second Y Tapped Hole") = False
Feature.Isactive("M10x18 Second Y Hole Mirror") = False
Elseif M10_Y_Qty = "3" Then
Feature.Isactive("M10x18 Y Middle Hole") = True
Feature.Isactive("M10x18 Second Y Tapped Hole") = False
Feature.Isactive("M10x18 Second Y Hole Mirror") = False
Elseif M10_Y_Qty = "4" Then
Vert_M8_Holes_Between_1_2_M10_Holes= Inputbox("Enter number of M8 holes between the first and second M10 hole, starting at top, on left hand side of the window frame","Vertical M8 Holes Between First & Second M10 Holes","2")
Feature.Isactive("M10x18 Y Middle Hole") = False
Feature.Isactive("M10x18 Second Y Tapped Hole") = True
Feature.Isactive("M10x18 Second Y Hole Mirror") = True
Else
Feature.IsActive("M10x18 Y Middle Hole") =False
Feature.Isactive("M10x18 Second Y Tapped Hole") = False
Feature.Isactive("M10x18 Second Y Hole Mirror") = False
End if
RuleParametersOutput()
InventorVb.DocumentUpdate()
iProperties.Value("Custom", "AllocationQty") = Round(AllocationQty, 3)
iProperties.Value("Summary", "Author") = iProperties.Value("Custom","User")
iProperties.Value("Project", "Designer") = iProperties.Value("Custom","User")
iProperties.Value("Project", "Creation Date") = iProperties.Value("Custom","Created")
iProperties.Value("Project","Project") = "MOX " & iProperties.Value("Summary","Subject")
RuleParametersOutput()
InventorVb.DocumentUpdate()
iLogicVb.UpdateWhenDone = True
iLogicVb.RunRule("Error Checking")
End Sub
Sub iLogicWakeup()
Dim tempV = Parameter.Quiet
tempV = m_pc39483c.Value(0)
tempV = MultiValue.Quiet
tempV = iLogicVb.UpdateWhenDone
tempV = iProperties.Value("Project", "Part Number")
' Any other iLogic objects (such as Feature or Component) that are used in the dialog should be listed here
End Sub
I didn't quite understand your comment about the other iLogic objects and listing them in the iLogicWakeup sub but I didn't think this would affect it keeping the timeout from happening.
If you need to see the vb code, let me know.
Thanks,
Randy