Hi there, new to the forum but hopefully I'll become an active member quite soon
.
Basically I have 2 comboboxes, Size and Part_No, I get the dreaded 2115 error while calling this event, the error claims that my beforeupdate property or validationrule property prohibit me from doing this, am i simply going about this the wrong way?
Private Sub Part_No_AfterUpdate()
Part_No.SetFocus
Dim pno As String
Dim res As String
pno = Part_No.Text
res = DLookup("[Size]", "product order", "[Part No] = '" & pno & "'")
MsgBox res
Size.SetFocus
Size.SelText = res 'This is the code that calls the error, basically i want it to make the combobox show the string res
End Sub
Thanks guys

Basically I have 2 comboboxes, Size and Part_No, I get the dreaded 2115 error while calling this event, the error claims that my beforeupdate property or validationrule property prohibit me from doing this, am i simply going about this the wrong way?
Private Sub Part_No_AfterUpdate()
Part_No.SetFocus
Dim pno As String
Dim res As String
pno = Part_No.Text
res = DLookup("[Size]", "product order", "[Part No] = '" & pno & "'")
MsgBox res
Size.SetFocus
Size.SelText = res 'This is the code that calls the error, basically i want it to make the combobox show the string res
End Sub
Thanks guys
