Microsoft Office Tutorials and References
In Depth Information
Making a Wizard with Tabbed Control
Finally the procedure sets the buttons as needed per page:
Private Sub SetButtons()¶
Select Case Me.tabWizard¶
Case 0¶
Me.btnPrev.Enabled = False¶
Me.btnNext.Enabled = True¶
Me.btnFinish.Enabled = False¶
Case 1¶
Me.btnPrev.Enabled = True¶
Me.btnNext.Enabled = True¶
Me.btnFinish.Enabled = False¶
Case 2¶
Me.btnPrev.Enabled = True¶
Me.btnNext.Enabled = True¶
Me.btnFinish.Enabled = False¶
Case 3¶
Me.btnPrev.Enabled = True¶
Me.btnNext.Enabled = False¶
Me.btnFinish.Enabled = True¶
End Select¶
End Sub¶
The tabbed control has a property Style on the Format tab that has these
options: Tabs, Buttons, or None. For the wizard, use None to hide the tabs and
to have full control over which page is displayed. The fact that the buttons are
placed above the control makes it necessary to use the Select Case, but saves a
lot of positioning and buttons that scatter the code over multiple events. In
general, it is best to get the navigation done in as few procedures as possible for
easy maintenance.
Acs
Search JabSto ::




Custom Search