Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have some information in one sheet that I want to copy and paste to another
sheet at the bottom of it (END + one sell), but now it looks like it will be pasted in the same cell, regardless how many rows i have in the source sheet and in the sheet that I paste the information in. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi,
To find the first empty cell after the last used row in a column use lastrow = Cells(Cells.Rows.Count, "A").End(xlUp).Row + 1 or if you don't know which column it's in use lastrow = ActiveSheet.UsedRange.Rows.Count + 1 Mike "Magnus HB" wrote: I have some information in one sheet that I want to copy and paste to another sheet at the bottom of it (END + one sell), but now it looks like it will be pasted in the same cell, regardless how many rows i have in the source sheet and in the sheet that I paste the information in. |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
The following code copies a range from Sheet1 and pastes it at the bottom of
the existing data in the first column of Sheet2. The code for the Copy/Paste is actually one line of code and the space and underscore at the end of lines are line breaks in an otherwise single line of code. Note that when you copy a range (that is multiple cells) you only need to address the first cell of the destination. Sheets("Sheet1").Range("A2:Z2").Copy _ Sheets("Sheet2").Cells(Rows.Count, 1) _ .End(xlUp).Offset(1, 0) To get the first blank cell in column 1 the code emulates the following:- Selecting the last cell in column A (At the very bottom of the worksheet.) Holding Ctrl key and pressing Up arrow. Moves the cursor up to the first cell with data. Press down arrow once to move to cell below the one with data. Hope this helps. -- Regards, OssieMac "Magnus HB" wrote: I have some information in one sheet that I want to copy and paste to another sheet at the bottom of it (END + one sell), but now it looks like it will be pasted in the same cell, regardless how many rows i have in the source sheet and in the sheet that I paste the information in. |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Post your code.
"Magnus HB" wrote: I have some information in one sheet that I want to copy and paste to another sheet at the bottom of it (END + one sell), but now it looks like it will be pasted in the same cell, regardless how many rows i have in the source sheet and in the sheet that I paste the information in. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Paste A Cell Formula Into A Cell With A Macro. | Excel Worksheet Functions | |||
Need macro to check if cell is not blank & previous cell is blank, copy information from row above & paste | Excel Programming | |||
Macro to paste in the active cell the contents of a cell from another file?? | Excel Programming | |||
macro to copy & paste cell data into another cell | Excel Programming | |||
Copy and Paste macro needs to paste to a changing cell reference | Excel Programming |