Hello,
I am workin with a db that has a form and a subform. The subform has a couple of controls on it that have If IsNull functions, then msg box. The only problem is that when the user clicks ok after an IsNull msg, The bogus value is still there. In fact, once I set focus away and back to the control it puts the cursor at the berginning, so I can't use a sendkeys del or backspace or something. I was under the impression that an 'undo' would delete the original entry. Here is an example of what I'm doing after update of 'jobno' control:
IF IsNull(Me!jobno) Then
MsgBox "You must scan a job number."
Me.undo
Me!wc.SetFocus
Me!jobno.SetFocus
End If
I just need a way to del the original value, or highlight the entire original value so if user messes up all they have to worry about is entereing a new value. Any help is always appreciated.
THanks
Jeremy
I am workin with a db that has a form and a subform. The subform has a couple of controls on it that have If IsNull functions, then msg box. The only problem is that when the user clicks ok after an IsNull msg, The bogus value is still there. In fact, once I set focus away and back to the control it puts the cursor at the berginning, so I can't use a sendkeys del or backspace or something. I was under the impression that an 'undo' would delete the original entry. Here is an example of what I'm doing after update of 'jobno' control:
IF IsNull(Me!jobno) Then
MsgBox "You must scan a job number."
Me.undo
Me!wc.SetFocus
Me!jobno.SetFocus
End If
I just need a way to del the original value, or highlight the entire original value so if user messes up all they have to worry about is entereing a new value. Any help is always appreciated.
THanks
Jeremy