PDA

View Full Version : Solved: Userform With Dropdown Selection



Nurofen
10-09-2007, 07:41 AM
Hi all,

I have a userform which I would like to have a dropdown list, so when the user picks the his/her option will be directed to the correct page.

Is it also possible to have the pages hidden or do they have to be showing in the workbook for the userform to work.



Thank you all for your time

Nurofen

YellowLabPro
10-09-2007, 07:52 AM
For the dropdown list you will use a combobox.
Are you asking if the sheet w/ the values in the combobox can be hidden?
The answer I believe is yes.

Nurofen
10-09-2007, 08:05 AM
Hi,

Combobox, would that mean that they would have to make 2 selection before being directed? or is it just the same as have a list that they can select from and be directed?

There are no sheets with the values on them, it would be sheet names is that possilble?


Thank you for your time

Nurofen

YellowLabPro
10-09-2007, 08:10 AM
I thought you said you had a Userform. If you do have an existing one, and you have a list in it, I am guessing you are using a Textbox, you would change this to a combobox. However in re-reading your post, it seems like you would want to create a Table of Contents that have hyperlinks on it.
I dont think you will be able to hyperlink from a choice in a dropdown menu.
But don't hold me to that.

Nurofen
10-09-2007, 08:14 AM
Sorry I'm not being clear,

I do have a userform which I have setup with Command Buttons, but the problem is there are so many buttons, so I was thinking if would it be possible to change the buttons to a dropdown list.



Thanks

Nurofen

lucas
10-09-2007, 12:03 PM
How about a listbox?

Nurofen
10-09-2007, 01:12 PM
Lucas,

That looks great and if I need to add buttons as extras I can change the size,
can a scroll bar be adding or is that automatic if the sheets become to much for the screen. only asking cause I can't test till Friday.

Thanking for your time and help

Nurofen

Can all the sheets in the workbook also be hidden and only appear when requested and hidden on the next selection.

lucas
10-09-2007, 01:20 PM
Simpler method.....right click on the sheet tab and select "show sheet"

YellowLabPro
10-09-2007, 01:24 PM
Very Nice Steve

lucas
10-09-2007, 01:32 PM
I see this requested fairly often.....
Not mine and I don't remember where it came from.....John I think.

Nurofen
10-09-2007, 01:44 PM
Lucas

Very very nice i like it, but sorry for the but, is there away to get away from having to select the tab and click unhide, the users will get confused I know its simple but..can there a command button on each sheet to bring up the unhide box..


I thank you very much for help

Nurofen

lucas
10-09-2007, 01:59 PM
yes but you're not going to like it....what happens when you add a new sheet?

Nurofen
10-09-2007, 02:11 PM
Thanks,

What else can I ask for..

question: why does the area behind turn grey when the box is moved? is there a way to stop that or is it just me?


Thanks again

Nurofen

lucas
10-09-2007, 02:16 PM
Look for the word Navigation after the word Help on the main menu.....see if that will work for ya.

lucas
10-09-2007, 02:18 PM
Thanks,

What else can I ask for..

question: why does the area behind turn grey when the box is moved? is there a way to stop that or is it just me?


Thanks again

Nurofen

This is starting to remind me of the Steve Martin Drunk Test....don't know if you're old enough to remember it but......

I would say not to move it.....select a sheet or hit cancel....

Like the doctor said when the patient complained that it hurts when I do this...doctor said don't do that.

Nurofen
10-09-2007, 02:25 PM
lol my friend,

lol

Thank you very much for your time


Nurofen

Just checked it the grey does not go, but does not mater it nice as it is again thank you for your time Lucas

Nurofen
10-09-2007, 03:16 PM
Hi,
Say I wanted to bring up the userform instead of the unhind box with the Nav icon how would i do that?


Thank you.

Nurofen

lucas
10-09-2007, 03:27 PM
I'm going to squeeze you just a little here and ask you to try to figure that out for yourself first....will help if you get stumped but you are supposed to be learning this so....you have in the previous posts everything(codewise and userforms) to do what you require.

Don't hesitate to post specific questions if you get in trouble.

Nurofen
10-09-2007, 03:38 PM
Lucas,

I goin to try.

I'll post back tomorow if i'm unable to figure it out. I've tried to change the name from This sheet to my userforms name that didn't work but I will try again.

Thank you again for you help

Nurofen

lucas
10-09-2007, 04:17 PM
Tip for you. Look at the onaction call in the menu and make it call the module that holds the userform.show code.

Nurofen
10-10-2007, 04:41 AM
Lucas,

I have been able to call the userform from the Commandbar, I have attached the completed file.


great stuff

Thanks again for all your help

Nurofen
10-13-2007, 07:19 AM
Hi all I just wanted to to put something back for all the help given to me here.

I have used mdmackillop guide to create my menus and I have used code from the example.xls file Lucas uploaded.

The Workbook only has one sheet Active, all the others are hidden, when you use the MyMenu in the Commandbar
you are able to select the sheet required and hide the active one

I hope this is helpful to others

Nurofen

lucas
10-13-2007, 09:07 AM
We're all learning with these type of projects.....nice work.

Nurofen
10-14-2007, 06:13 AM
No problem Lucas happy to give back

Nurofen