E
excelent
Hi fellows
I got a Userform with 6 Checkbox'es
and 1 Commandbutton
What i wont is check out som of the 6's checboxes
when i click on commandutton the sheets/checkbox
i checked out is selected
here is what i got - what do i do ?
Private Sub CommandButton1_Click()
If UserForm1.CheckBox1 = True Then pr1 = "Ark1"
If UserForm1.CheckBox2 = True Then pr2 = "Ark2"
If UserForm1.CheckBox3 = True Then pr3 = "Ark3"
If UserForm1.CheckBox4 = True Then pr4 = "Ark4"
If UserForm1.CheckBox5 = True Then pr5 = "Ark5"
If UserForm1.CheckBox6 = True Then pr6 = "Ark6"
'MsgBox ("") & pr1 & "," & pr2 & "," & pr3 & "," & pr4 & "," & pr5 & "," & pr6
x = pr1 & "," & pr2 & "," & pr3 & "," & pr4 & "," & pr5 & "," & pr6
Sheets(Array(x)).Select
'Sheets(Array(pr1, pr2, pr3, pr4, pr5)).Select
End Sub
thanks in advance
I got a Userform with 6 Checkbox'es
and 1 Commandbutton
What i wont is check out som of the 6's checboxes
when i click on commandutton the sheets/checkbox
i checked out is selected
here is what i got - what do i do ?
Private Sub CommandButton1_Click()
If UserForm1.CheckBox1 = True Then pr1 = "Ark1"
If UserForm1.CheckBox2 = True Then pr2 = "Ark2"
If UserForm1.CheckBox3 = True Then pr3 = "Ark3"
If UserForm1.CheckBox4 = True Then pr4 = "Ark4"
If UserForm1.CheckBox5 = True Then pr5 = "Ark5"
If UserForm1.CheckBox6 = True Then pr6 = "Ark6"
'MsgBox ("") & pr1 & "," & pr2 & "," & pr3 & "," & pr4 & "," & pr5 & "," & pr6
x = pr1 & "," & pr2 & "," & pr3 & "," & pr4 & "," & pr5 & "," & pr6
Sheets(Array(x)).Select
'Sheets(Array(pr1, pr2, pr3, pr4, pr5)).Select
End Sub
thanks in advance