Changing forms Cycle setting

Peter Bellamy

Registered User.
Local time
Today, 02:23
Joined
Dec 3, 2005
Messages
295
I have a Form with a subform. The subform can have several records relating to the form but usually has only one.

I want to stop the subform allways rolling onto the next blank record when the user tabs out of the last field, the cycle setting should do that.

I built a short message box and if function on the last controls On Exit event for the user to choose a new sub record or not but it does not work !!

Dim response As Integer
response = MsgBox("Add another part to this Return record?", 292, "Part or New Record")
If response = 6 Then ' Yes chosen
Me.Cycle = 0
Else
Me.Cycle = 1
End If


Any thoughts why?

Cheers
 
Look at attachment (word, zip). Access help about moving between a main form and a subform.
 

Attachments

Thanks but that does not answer my question.
I want the movement to require no special knowledge of keystrokes.
 
Thanks vba that worked fine when I added a setfocus line to provide a destination for the cursor.
 

Users who are viewing this thread

Back
Top Bottom