Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 132
Default drop down list on form

Hi there

I have a form that opens automatically when the file is opened. I want to
add a drop down list to the form that has the names of the worksheets, and
when one is selected, it goes to the worksheet selected.

Is that possible, if so, how is it done?


--
Thank-you!
Ruth
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 293
Default drop down list on form

There will be a easier way than this however this is one way

It can be doe not in one action but two

Set up you list ie Sheet 1, sheet 2, sheet3 etc

Us the dropdown list cell number in an If Formula which will be in the cell
above your drop down list

=IF(M16="SHEET 1",HYPERLINK("#'Road Cash Accounting'!AI2","Road cash
accounting PLEASE PRESS"), IF(M16="SHEET 2" etc,tec

In this case if sheet one is selected in your drop down list in M16,the
cell containing the above formula will appear as A HYPERLINK TO "road cash
accounting PLEASE PRESS"
THIS WOULD TAKE YOU TO ROAD CASH ACCOUNTING SHEET CELL AI2

IN excel 2003 you can have 7 if formulas , in 2007 I believe more

Hope this helps

Stewart





"Ruth" wrote:

Hi there

I have a form that opens automatically when the file is opened. I want to
add a drop down list to the form that has the names of the worksheets, and
when one is selected, it goes to the worksheet selected.

Is that possible, if so, how is it done?


--
Thank-you!
Ruth

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 772
Default drop down list on form

I think this is what you want, code is on the userform
Private Sub ComboBox1_Change()
Sheets(ComboBox1.Text).Select
End Sub

Private Sub UserForm_Activate()
For Each Sheet In ActiveWorkbook.Sheets
ComboBox1.AddItem (Sheet.Name)
Next
End Sub
--
-John
Please rate when your question is answered to help us and others know what
is helpful.


"Ruth" wrote:

Hi there

I have a form that opens automatically when the file is opened. I want to
add a drop down list to the form that has the names of the worksheets, and
when one is selected, it goes to the worksheet selected.

Is that possible, if so, how is it done?


--
Thank-you!
Ruth

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 132
Default drop down list on form

Sorry to take so long to get back-- had to set the project aside for a bit

Thank-you both. I used John's answer- it just seemed a bit easier and it
worked great.

This there a code that will open the worksheet so that cell A1 is the active
cell when it opens?


--
Thank-you!
Ruth


"John Bundy" wrote:

I think this is what you want, code is on the userform
Private Sub ComboBox1_Change()
Sheets(ComboBox1.Text).Select
End Sub

Private Sub UserForm_Activate()
For Each Sheet In ActiveWorkbook.Sheets
ComboBox1.AddItem (Sheet.Name)
Next
End Sub
--
-John
Please rate when your question is answered to help us and others know what
is helpful.


"Ruth" wrote:

Hi there

I have a form that opens automatically when the file is opened. I want to
add a drop down list to the form that has the names of the worksheets, and
when one is selected, it goes to the worksheet selected.

Is that possible, if so, how is it done?


--
Thank-you!
Ruth

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Drop down list dependant on previous drop down list Tenacioushail Excel Discussion (Misc queries) 1 July 1st 08 11:35 AM
User Form - Get Data From Drop List Tony Excel Discussion (Misc queries) 0 January 7th 08 08:54 PM
Form drop down list dg Excel Worksheet Functions 3 July 11th 07 05:17 PM
Drop Down List choice selecting another drop down list CVD0722 Excel Worksheet Functions 3 October 31st 06 01:02 PM
multiple select from the drop down list in excel. list in one sheet and drop down in sriramus Excel Discussion (Misc queries) 5 October 27th 05 06:55 PM


All times are GMT +1. The time now is 08:12 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"