View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Dianne Butterworth Dianne Butterworth is offline
external usenet poster
 
Posts: 7
Default Non contiguous to contiguous

Neal,

Try this -

Sub PlaceData()

Dim rng As Range
Dim c As Range
Dim rngPlace As Range

'set this to be the starting point for your data
Set rngPlace = ActiveSheet.Range("G1")

For Each rng In ActiveWorkbook.Names("Data").RefersToRange.Areas
For Each c In rng
rngPlace.Value = c.Value
Set rngPlace = rngPlace.Offset(1, 0)
Next c
Next rng

End Sub

--
HTH,
Dianne Butterworth

In ,
Neal typed:
Hi,

My data is in non-contiguous cells within a named range "Data"
(C8:AG18).

Could someone please assist with a macro that will copy the data from
all
cells containing data within this range and place them contiguously
in a column for charting purposes.


Thank U