Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
What is the best way of doing this and how.
This is what I want.... MultiPage1.Value =0 Cancel Next MultiPage1.Value =1 Previous Next MultiPage1.Value =2 Previous Finish Is it best to create one of each and then make then visible/invisible for each tab ( and how do you do this) Or is it best to generate each one on each tab seperately. If so, can you then group all the Nexts together to write one sub that will move to the next page rather than having to generage duplicate subs for each button. Both the above ways I have tried but stumble on both. 1st option I can't get the right syntax to make visible/invisible which I am trying to do under the MultiPage1_Change() which apparently isn't valid. 2nd option I can make a new collection of the next buttons but then don't know how to use that group to attach to code to raise the tab number. Can anybody help ? Thanking you in advance. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I would create 4 buttons,not on the multipage, but on the form, overlaying
Cancel and previous, and also Next and Finish and hide and unhide them as each page is activated. Like this Private Sub MultiPage1_Change() If Me.MultiPage1.Value = 0 Then Me.cmdCancel.Visible = True Me.cmdPrevious.Visible = False Me.cmdNext.Visible = True Me.cmdFinish.Visible = False ElseIf Me.MultiPage1.Value = 1 Then Me.cmdCancel.Visible = False Me.cmdPrevious.Visible = True Me.cmdNext.Visible = False Me.cmdFinish.Visible = True End If End Sub Private Sub UserForm_Activate() Me.cmdCancel.Visible = True Me.cmdPrevious.Visible = False Me.cmdNext.Visible = True Me.cmdFinish.Visible = False End Sub -- HTH Bob Phillips wrote in message oups.com... What is the best way of doing this and how. This is what I want.... MultiPage1.Value =0 Cancel Next MultiPage1.Value =1 Previous Next MultiPage1.Value =2 Previous Finish Is it best to create one of each and then make then visible/invisible for each tab ( and how do you do this) Or is it best to generate each one on each tab seperately. If so, can you then group all the Nexts together to write one sub that will move to the next page rather than having to generage duplicate subs for each button. Both the above ways I have tried but stumble on both. 1st option I can't get the right syntax to make visible/invisible which I am trying to do under the MultiPage1_Change() which apparently isn't valid. 2nd option I can make a new collection of the next buttons but then don't know how to use that group to attach to code to raise the tab number. Can anybody help ? Thanking you in advance. |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks for the reply Bob.
That works a treat but I have to change tabs on the multichange for it to change to what should be showing, so taking a logical guess I have to set set state of the multipage (ie tab1) and the state of which buttons I want visible before I show the userform...correct ? and do I do this using a .... Private Sub UserForm_Initialize() One last thing.....can you explain what the ' Me ' is. I've seen it a lot and to be honest have never done a search in this forum on ' Me ' . Thanks for your help. |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Yes, but I gave you that although I did it in the Activate event, not
Initialize, but both work. -- HTH Bob Phillips wrote in message oups.com... Thanks for the reply Bob. That works a treat but I have to change tabs on the multichange for it to change to what should be showing, so taking a logical guess I have to set set state of the multipage (ie tab1) and the state of which buttons I want visible before I show the userform...correct ? and do I do this using a .... Private Sub UserForm_Initialize() One last thing.....can you explain what the ' Me ' is. I've seen it a lot and to be honest have never done a search in this forum on ' Me ' . Thanks for your help. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
how to cancel a cut command connected to arrow down | Excel Discussion (Misc queries) | |||
Syntax Problem : Grouping Buttons On A Multipage | Excel Programming | |||
Create Next and Previous Buttons on Userform | Excel Programming | |||
Control Buttons vs. Command Buttons | Excel Programming | |||
Cancel buttons in Msgbox | Excel Programming |