Home |
Search |
Today's Posts |
#7
Posted to microsoft.public.excel.misc
|
|||
|
|||
Selecting sheet with VB
Mike,
Now says Subscript out of range. Rob "Mike H" wrote in message ... Try, Dim ss As String ss = Sheets("Sheet60").Range("d2").Value Sheets(ss).Select Mike "RobN" wrote: (I posted this in the office.misc newsgroup by mistake) I've used the following to try and have VB select a sheet dependant on the value in d2. Dim ss As Variant Set ss = Sheet60.Range("d2") How do I apply that now to select that sheet? I thought something like sheet(ss).select would do it, but it doesn't work Sheets(ss).select does work, but doesn't go to the correct sheet number, whereas Sheet(ss) brings up a "Sub or Function not defined" error. Rob |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Need to update a ComboBox when selecting a sheet | Excel Worksheet Functions | |||
Display MsgBox when selecting a sheet | Excel Discussion (Misc queries) | |||
Selecting active area of sheet | Excel Discussion (Misc queries) | |||
Selecting Last Sheet | Excel Worksheet Functions | |||
Selecting a sheet from a drop down box | Excel Discussion (Misc queries) |