Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
"Split Unioned Ranges"
Good Day Group, Is there another way to "split" the "result" -variable from the code below into variables of type: r = Range("C2:F2") etc. With my limited knowledge I can only think of do it with Len and Mid functions. Brgds CG Rosén --------------------------------------------------------------- Dim rng As Range, cell As Range Dim rngList() As Range, i As Long For Each cell In Rows(3).Cells If cell.Interior.ColorIndex = 15 Then If rng Is Nothing Then Set rng = cell Else Set rng = Union(rng, cell) End If End If Next If Not rng Is Nothing Then result = rng.Address(RowAbsolute:=False, ColumnAbsolute:=False) End If MsgBox result |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
"Split Unioned Ranges"
CG Rosén wrote:
Is there another way to "split" the "result" -variable from the code below into variables of type: Dim R As Range For Each R In Rng.Areas MsgBox R.Address Next Bill Manville MVP - Microsoft Excel, Oxford, England No email replies please - reply in newsgroup |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How do I use "sumif" for cells "0" across multiple ranges? | Excel Discussion (Misc queries) | |||
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell | Excel Discussion (Misc queries) | |||
change "true" and "false" to "availble" and "out of stock" | Excel Worksheet Functions | |||
HELP on "left","right","find","len","substitute" functions | Excel Discussion (Misc queries) | |||
Count occurences of "1"/"0" (or"TRUE"/"FALSE") in a row w. conditions in the next | New Users to Excel |