UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Controlling navigation in an access form    
 
   
mje397
post Mar 3 2005, 11:34 AM
Post #1

New Member
Posts: 11



Is it possible to control the navigation between the various entities in a form .. for eg I have

Combobox 1
Textbox 2
Combobox 3

If value of "combobox 1" is say 2 then go to "textbox 2" or else go to combobox 3..

Thnx in advance
Go to the top of the page
 
+
Jack Cowley
post Mar 3 2005, 11:46 AM
Post #2

Retired Moderator
Posts: 37,716
From: The San Francisco Bay Area



Welcome to Utter Access Forums!

In the After Update event of Combobox1:

If Me.ComboBox1 = 2 Then
Me.TextBox2.SetFocus
Else
Me.ComboBox3.SetFocus
End If

hth,
Jack
Go to the top of the page
 
+
mje397
post Mar 3 2005, 12:08 PM
Post #3

New Member
Posts: 11



thnx jack,, It is working if I give ... Me.combobox=1 then..

But when I use an OR control is not going where I want.. Am i missing something.. ??

This is my code.

If Me.Combo18 = 1 Or 2 Then
Me.Combo22.SetFocus
Else
Me.Combo20.SetFocus
End If
Go to the top of the page
 
+
Jack Cowley
post Mar 3 2005, 12:10 PM
Post #4

Retired Moderator
Posts: 37,716
From: The San Francisco Bay Area



This will work:

If Me.Combo18 = 1 Or Me.Combo18 = 2 Then
Me.Combo22.SetFocus
Else
Me.Combo20.SetFocus
End If

Jack
Go to the top of the page
 
+
mje397
post Mar 3 2005, 12:12 PM
Post #5

New Member
Posts: 11



Thnx a bunch
Go to the top of the page
 
+
Jack Cowley
post Mar 3 2005, 12:16 PM
Post #6

Retired Moderator
Posts: 37,716
From: The San Francisco Bay Area



You are welcome...

Jack
Go to the top of the page
 
+

Thank you for your support! Reply to this topicStart new topic

Jump To Forum:
 



RSS Go to Top  ·  Lo-Fi Version Time is now: 22nd May 2013 - 07:08 AM