A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » New Users
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

previous field



 
 
Thread Tools Display Modes
  #1  
Old November 29th, 2004, 05:02 PM
Bre-x
external usenet poster
 
Posts: n/a
Default previous field

Hi,
I have this function on a datasheet form.
It doesnt work. After i click Ok, the focus doesnt stay with the RQTY
field, it actually moves to the next record.
Is there something like go back to last focus?

Private Sub RQTY_LostFocus()
If Me.R = -1 Then 'Yes we want to ship this line
MsgBox ("Must Enter Qty other thant '0'")
Me.RQTY.SetFocus
If Me.RQTY = 0 Then
Me.RQTY.SetFocus
Else
End If
Else
End If
End Sub


  #2  
Old November 29th, 2004, 09:28 PM
B. Comrie
external usenet poster
 
Posts: n/a
Default

In the form properties set the Cycle Records Property to Current Record.

B Comrie
http://www.codewidgets.com

"Bre-x" wrote in message
...
Hi,
I have this function on a datasheet form.
It doesnt work. After i click Ok, the focus doesnt stay with the RQTY
field, it actually moves to the next record.
Is there something like go back to last focus?

Private Sub RQTY_LostFocus()
If Me.R = -1 Then 'Yes we want to ship this line
MsgBox ("Must Enter Qty other thant '0'")
Me.RQTY.SetFocus
If Me.RQTY = 0 Then
Me.RQTY.SetFocus
Else
End If
Else
End If
End Sub




 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Field not in Field List: What to do? Jerry Crosby Using Forms 3 November 18th, 2004 03:19 PM
Access 2000, autonumber fields Zyberg74 General Discussion 3 November 17th, 2004 04:24 PM
entering previous record field value Gonzalo Using Forms 1 September 9th, 2004 03:38 PM
Field list greyed out when trying to add an option group Tony Using Forms 1 July 1st, 2004 03:40 AM


All times are GMT +1. The time now is 03:08 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.