How to use combobox to select different sheet?

anthonymedz

Board Regular
Joined
Jan 30, 2015
Messages
69
Hi guys,

Can you help me on this. I know this is simple to you. I have a project that i need to simply use a combobox in a userform to select a sheet per categories.
For example, if i have a category of Fruits and use the combo box it will have a drop down of mango and will select on that particular sheet.

Fruits(Combobox1)
Mango(sheet1)
Banana(sheet2)
Guava(sheet3)

Cars(Combobox2)
Toyota(Sheet4)
Honda(sheet5)
Mitsubishi(sheet6)

Thanks for the advance help.
 

Excel Facts

Enter current date or time
Ctrl+: enters current time. Ctrl+; enters current date. Use Ctrl+: Ctrl+; Enter for current date & time.
So you have a ComboBox Named ComboBox1.

And When you select on Mango you want to be taken to a sheet named Mango.
Is that what you want.

It not please explain again.
 
Upvote 0
Maybe
Code:
Private Sub ComboBox1_Change()
Sheets(ComboBox1.Value).Select
Unload Me
End Sub
 
Upvote 0
Now if you Open your Userform like this:
Userform1.show Modeless

You can work on your sheet while you have Your Userform visible.

And use a script like this:
Code:
Private Sub ComboBox1_Change()
'Modified  2/21/2019  12:53:50 AM  EST
Application.Goto Sheets(ComboBox1.Value).Range("B3"), Scroll:=True
End Sub
 
Upvote 0
Hi Sir,

yes you are correct.
If im going to select the Combobox1 there is a drop down list of Mango, Banana, Guava and will taken me to that sheet if im going to choose that kind of fruits.
 
Upvote 0
So you have a ComboBox Named ComboBox1.

And When you select on Mango you want to be taken to a sheet named Mango.
Is that what you want.

It not please explain again.


Hi Sir,

yes you are correct.
If im going to select the Combobox1 there is a drop down list of Mango, Banana, Guava and will taken me to that sheet if im going to choose that kind of fruits.
 
Upvote 0
Now if you Open your Userform like this:
Userform1.show Modeless

You can work on your sheet while you have Your Userform visible.

And use a script like this:
Code:
Private Sub ComboBox1_Change()
'Modified  2/21/2019  12:53:50 AM  EST
Application.Goto Sheets(ComboBox1.Value).Range("B3"), Scroll:=True
End Sub

Sorry.. i tried your code but its not working. I cant see anything when i click the combobox1.
 
Upvote 0
So you can see a sheet name in the Combobox Correct?
And if you click on the sheet name you should be taken to that sheet. If you have installed my script in the combobox.
 
Upvote 0
So are you saying you do not see anything in the Combobox?

So if you want to use a Combobox to go to certain sheets you first must load the combobox with the sheet names.

Have you done that?

Do you want to load all sheet names into the combobox and then select which one you want to go to when you select it from the combobox
 
Upvote 0
So are you saying you do not see anything in the Combobox?

So if you want to use a Combobox to go to certain sheets you first must load the combobox with the sheet names.

Have you done that?

Do you want to load all sheet names into the combobox and then select which one you want to go to when you select it from the combobox



Yes, you are correct. I want to load all sheet names into the combobox1 and then go to that sheet when i select it from the combobox.
 
Upvote 0

Forum statistics

Threads
1,223,889
Messages
6,175,224
Members
452,620
Latest member
dsubash

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top