Share via

VBA Forms multipage pages

Anonymous
2013-01-17T18:06:54+00:00

The help system doesn't explain if this is possible, i'd rather avoid using sendkeys.

On an Excel VBA user form i have a multipage control with 3 pages, Page1, Page2, Page3

On the Page1 tab I put a next button. I need code for the next buttons click event to navigate from page1 to page2

TIA

Microsoft 365 and Office | Excel | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Anonymous
2013-01-17T19:12:23+00:00

If you put the button outside the multipage control you can use the following to move next through all pages:

=======================================

With Me.MultiPage1

If .Value + 1 < .Pages.Count Then .Value = .Value + 1

End With

========================================

To move backwards put another button OUTSIDE the Multipage control and add the follwoing code:

=======================================

With Me.MultiPage1

If .Value + 1 > 1 Then .Value = .Value - 1

End With

=======================================

Was this answer helpful?

2 people found this answer helpful.
0 comments No comments

0 additional answers

Sort by: Most helpful