Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Dim cells in a sheet as a range
I am using a Select Case statement, and instead of having many Case
statements to cover ALL cell senarios, how can i use a line to 'DIM" an array of cells? Rather than something like: Case Is = Sheet4.range("A1") ' code 1 Case Is = Sheet4.range("C3") ' code 2 Case Is = Sheet4.range("H10") ' code 3 etc............ How can i use some thing like: Dim sh as Sheet4 Dim rng as Range Set rng = sh.Cells("A1,C3,H10,...........") Case Select Sheet1.range("D2").value Case sh.rng ' code to work for ALL rng senario's.... end Select How can i Syntax this? |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Change range from cells to sheet? | Excel Worksheet Functions | |||
How to transfer text to an sheet if the cells en range contains a | Excel Discussion (Misc queries) | |||
Concatenating a range of cells from another sheet, possible? | Excel Worksheet Functions | |||
code to copy a range of cells to another sheet | Excel Programming | |||
Smallest range on sheet containing non-blank cells? | Excel Programming |