![]() |
Copying an unspecified column range
Hi,
Need help from you Guys. I want to create a personal macro that will copy a range from the active cell down below (more likely up to 400 rows). I need your code / help very badly. Thanks in advance. Jerome |
Copying an unspecified column range
Hi Jerome
One column Range(ActiveCell, ActiveCell.End(xlDown)).copy or if you want to copy all column in the range Range(ActiveCell, ActiveCell.End(xlDown)).EntireRow.copy Regards, Per "jhong" skrev i meddelelsen ... Hi, Need help from you Guys. I want to create a personal macro that will copy a range from the active cell down below (more likely up to 400 rows). I need your code / help very badly. Thanks in advance. Jerome |
Copying an unspecified column range
Copy to where?
Sub copy_column() Dim rng2 As Range Set rng2 = Sheets("Sheet2").Range("A1") Range(ActiveCell, Cells(Rows.Count, ActiveCell.Column) _ .End(xlUp)).Copy Destination:=rng2 End Sub Best to select from bottom up in case there blank cells in the range. xlDown will stop at first blank cell. Gord Dibben MS Excel MVP On Wed, 9 Jul 2008 01:03:27 -0700 (PDT), jhong wrote: Hi, Need help from you Guys. I want to create a personal macro that will copy a range from the active cell down below (more likely up to 400 rows). I need your code / help very badly. Thanks in advance. Jerome |
Copying an unspecified column range
On Jul 10, 6:37*am, Gord Dibben <gorddibbATshawDOTca wrote:
Copy to where? Sub copy_column() Dim rng2 As Range * * Set rng2 = Sheets("Sheet2").Range("A1") * * * *Range(ActiveCell, Cells(Rows.Count, ActiveCell.Column) _ * * .End(xlUp)).Copy Destination:=rng2 End Sub Best to select from bottom up in case there blank cells in the range. xlDown will stop at first blank cell. Gord Dibben *MS Excel MVP On Wed, 9 Jul 2008 01:03:27 -0700 (PDT), jhong wrote: Hi, Need help from you Guys. I want to create a personal macro that will copy a range from the active cell down below (more likely up to 400 rows). I need your code / help very badly. Thanks in advance. Jerome- Hide quoted text - - Show quoted text - Thanks a lot Jessen and Gord for the reply! Here's the code that i need coming from Gord, Range(ActiveCell, Cells(Rows.Count, ActiveCell.Column).End(xlUp)).Copy Kudos to both of you!! |
Copying an unspecified column range
Now that you have copied the range, what will you do with it?
You don't always have to select something to copy or move it. But if you're happy with what you've got.........OK Thanks for the feedback Gord On Fri, 11 Jul 2008 06:00:15 -0700 (PDT), jhong wrote: Thanks a lot Jessen and Gord for the reply! Here's the code that i need coming from Gord, Range(ActiveCell, Cells(Rows.Count, ActiveCell.Column).End(xlUp)).Copy Kudos to both of you!! |
All times are GMT +1. The time now is 07:18 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com