When I click the Next
button on the form I would like to get the next part on the Form
I have a for
loop that goes through Product Tree and reads PartName
in variable oForm.txtPartName
. On oForm
there is a button Next
and what it's supposed to do is break the for
loop and jump on the next part on the tree. What code should I put into the Next
button to get the job done?
For i = 1 To oProducts.Count
On Error Resume Next
Set oPartDoc = oProducts.Item(i).ReferenceProduct.Parent
Set oPart = oPartDoc.part
If CInt(Mid(oPart.Name, 26, 3)) > 100 Then
oForm1.txtPartName = oPart.Name
oForm1.Show
End If
Next i