Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Dynamically adding data after the last column
I want to do the following
Set a dynamic range name of USED Range First row is row 30 First column is column A Last column is the last column of data in row 30. Last row is the last row of data in the last column. Once that named range is defned, I want to copy the data in the last column of data over one column. AND ... I want to do this all programmatically or with a predefined range name. Can someone assist? Thanks |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Dynamically adding data after the last column
Dim R As Range
Set R = Range("A30", Range("A30").End(xlToRight).End(xlDown)) -- Charles Chickering "A good example is twice the value of good advice." "Barb Reinhardt" wrote: I want to do the following Set a dynamic range name of USED Range First row is row 30 First column is column A Last column is the last column of data in row 30. Last row is the last row of data in the last column. Once that named range is defned, I want to copy the data in the last column of data over one column. AND ... I want to do this all programmatically or with a predefined range name. Can someone assist? Thanks |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Dynamically adding data after the last column
That answered the first part of my question. What do I need to do to copy
the data over one column from the last column? "Charles Chickering" wrote: Dim R As Range Set R = Range("A30", Range("A30").End(xlToRight).End(xlDown)) -- Charles Chickering "A good example is twice the value of good advice." "Barb Reinhardt" wrote: I want to do the following Set a dynamic range name of USED Range First row is row 30 First column is column A Last column is the last column of data in row 30. Last row is the last row of data in the last column. Once that named range is defned, I want to copy the data in the last column of data over one column. AND ... I want to do this all programmatically or with a predefined range name. Can someone assist? Thanks |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Dynamically adding data after the last column
Thanks. That answered part of it. What I really want to do is select the
range of cells that is one cell immediately to the right of this range. How do I do that? "Charles Chickering" wrote: Dim R As Range Set R = Range("A30", Range("A30").End(xlToRight).End(xlDown)) -- Charles Chickering "A good example is twice the value of good advice." "Barb Reinhardt" wrote: I want to do the following Set a dynamic range name of USED Range First row is row 30 First column is column A Last column is the last column of data in row 30. Last row is the last row of data in the last column. Once that named range is defned, I want to copy the data in the last column of data over one column. AND ... I want to do this all programmatically or with a predefined range name. Can someone assist? Thanks |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Dynamically adding data after the last column
Sry, Missed that.
Dim R As Range Set R = Range("A30", Range("A30").End(xlToRight).End(xlDown)) Range(R.Cells(1, R.Columns.Count), R.Cells(R.Rows.Count, _ R.Columns.Count)).Copy R.Cells(1, R.Columns.Count).Offset(, 1) -- Charles Chickering "A good example is twice the value of good advice." "Barb Reinhardt" wrote: That answered the first part of my question. What do I need to do to copy the data over one column from the last column? "Charles Chickering" wrote: Dim R As Range Set R = Range("A30", Range("A30").End(xlToRight).End(xlDown)) -- Charles Chickering "A good example is twice the value of good advice." "Barb Reinhardt" wrote: I want to do the following Set a dynamic range name of USED Range First row is row 30 First column is column A Last column is the last column of data in row 30. Last row is the last row of data in the last column. Once that named range is defned, I want to copy the data in the last column of data over one column. AND ... I want to do this all programmatically or with a predefined range name. Can someone assist? Thanks |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Dynamically adding a macro to a new worksheet | Excel Programming | |||
Dynamically adding code | Excel Programming | |||
Adding Pivot Tables Dynamically | Excel Programming | |||
Dynamically adding data to a Combobox? | Excel Programming | |||
Adding button dynamically | Excel Programming |