=TB=
Registered User.
- Local time
- Today, 21:21
- Joined
- Aug 13, 2002
- Messages
- 68
I am using this code in the on exit of a field on my subform,
Private Sub Quantity_Exit(Cancel As Integer)
Dim intQty As Integer
intQty = Quantity
If intQty > 0 Then
Quantity = -Quantity
End If
End Sub
Works fine, however if the Qty is >0 then I have hit Tab twice to move to the next field (Once to convert the number to a Minus and Once again to tab). I think I see why this is happening, should I have an instruction in the sub to tell focus to move to the next field and if so what would that code be.
Thanks in advance.
Private Sub Quantity_Exit(Cancel As Integer)
Dim intQty As Integer
intQty = Quantity
If intQty > 0 Then
Quantity = -Quantity
End If
End Sub
Works fine, however if the Qty is >0 then I have hit Tab twice to move to the next field (Once to convert the number to a Minus and Once again to tab). I think I see why this is happening, should I have an instruction in the sub to tell focus to move to the next field and if so what would that code be.
Thanks in advance.
Last edited: