Solved

VBA - Word, Toggle Show/hide Multipages in Userform

Posted on 2015-01-07
7
324 Views
Last Modified: 2015-01-07
Hi guys,

I'm quite new at VBA, and working on a big project with a word document and vba.

I need some help with being able to toggle a multipage show/hide. I have gotten this far that i'm able to toggle it to show but not the other way around.

please help,

this is the code i'm using:

Me.MultiPage1.Pages(2).Visible = True

Open in new window

0
Comment
Question by:Hakum
  • 4
  • 3
7 Comments
 
LVL 48

Expert Comment

by:Rgonzo1971
ID: 40535685
Hi

if you want to hide the second page do use 1 (zero based)

Me.MultiPage1.Pages(1).Visible = False

Regards
0
 
LVL 1

Author Comment

by:Hakum
ID: 40535706
I want to unhide the 3rd and onwards pages depending on if its checked in diffrent checkboxs on page 2

View the attachment for the doc im working with at the moment
0
 
LVL 48

Expert Comment

by:Rgonzo1971
ID: 40535709
No file
0
What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

 
LVL 1

Author Comment

by:Hakum
ID: 40535711
0
 
LVL 1

Author Comment

by:Hakum
ID: 40535719
try now :) something went wrong
0
 
LVL 48

Accepted Solution

by:
Rgonzo1971 earned 500 total points
ID: 40535733
Hi,

pls try

Private Sub CheckBox14_Click()

'On/Off Toggle
Dim ctrl As Control

    For Each ctrl In Me.Frame15.Controls
        ctrl.Enabled = Not (ctrl.Enabled)
    Next

Me.MultiPage1.Pages(2).Visible = CheckBox14.Value

End Sub

Open in new window

And so on...

Regards
0
 
LVL 1

Author Closing Comment

by:Hakum
ID: 40535751
YOU ROCK!!! THANKS A TON!! :D
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
The view will learn how to download and install SIMTOOLS and FORMLIST into Excel, how to use SIMTOOLS to generate a Monte Carlo simulation of 30 sales calls, and how to calculate the conditional probability based on the results of the Monte Carlo …
Learn how to make your own table of contents in Microsoft Word using paragraph styles and the automatic table of contents tool. We'll be using the paragraph styles in Word’s Home toolbar to help you create a table of contents. Type out your initial …

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now