P
PeterM
I'm having problems with AC2003. I have code for the AfterUpdate of a text
field. In there I...
If Not Me.txtCostCenter > "" Or IsNull(Me.txtCostCenter) Then
style = vbCritical + vbOKOnly
title = "Data Error!"
msg = "Cost Center is required!"
response = MsgBox(msg, style, title)
Cancel = True
Me.txtCostCenter.SetFocus
End If
when you enter a value in the txtCostCenter to cause an error, it displays
the msgbox and then setsfocus to the next field in the tab order, not on
txtCostCenter. I simply want the cursor back to the field in error after it
displays the msgbox. Can anyone help?
thanks in acvance
field. In there I...
If Not Me.txtCostCenter > "" Or IsNull(Me.txtCostCenter) Then
style = vbCritical + vbOKOnly
title = "Data Error!"
msg = "Cost Center is required!"
response = MsgBox(msg, style, title)
Cancel = True
Me.txtCostCenter.SetFocus
End If
when you enter a value in the txtCostCenter to cause an error, it displays
the msgbox and then setsfocus to the next field in the tab order, not on
txtCostCenter. I simply want the cursor back to the field in error after it
displays the msgbox. Can anyone help?
thanks in acvance