go to another section of form using command button

  • Thread starter Thread starter Maggie
  • Start date Start date
M

Maggie

I have a form that has many tabs. When a user finishes
updating the information on one tab I want to add command
button that will advance them to the next tab. The tabs
are forms that I have created and then pasted on the tabs
so I don't know if I should open the form - even though it
is already open as part of the sub form.

I will need to do this of the tabs.

Any ideas??

Maggie
 
Maggie,

No, it is not correct to try to "open" the subforms. Instead, put code
on the Click event of the command buttons, along these lines...
Me.NameOfNextTabPage.SetFocus
 
Hi Maggie,

I just done the same sort of thing, so hopefully this will help. I am
assuming your tab form is called 'tabform', and you have 'form1', 'form2',
etc on your tabs.

If you want your focus to go from [lastfield] on 'form1' to [firstfield] on
'form2', then use the AfterUpdate event of [lastfield] to move it... insert
this line of code in the After Update event of [lastfield]...

Forms![tabform]![form2].SetFocus

hope that helps

DubboPete
 
Steve - Thanks this worked great! Maggie
-----Original Message-----
Maggie,

No, it is not correct to try to "open" the subforms. Instead, put code
on the Click event of the command buttons, along these lines...
Me.NameOfNextTabPage.SetFocus

--
Steve Schapel, Microsoft Access MVP


.
 
Back
Top