Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8
Default Last Row of Data

Hi:

Can any one tell me how I would go about selecting a
specific worksheet, then finding the last row with data
in it, selecting the next row and pasting in copied data
from another worksheet.

Thanks,

Sam
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default Last Row of Data

Sam,

Try something like

Dim LastCell As Range
Set LastCell = Worksheets("Sheet1").Cells(Rows.Count,
"A").End(xlUp)(2, 1)
LastCell.Worksheet.Select
LastCell.Select


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com



"Sam Fowler" wrote in
message ...
Hi:

Can any one tell me how I would go about selecting a
specific worksheet, then finding the last row with data
in it, selecting the next row and pasting in copied data
from another worksheet.

Thanks,

Sam



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 340
Default Last Row of Data

Sam, to select a worksheet:

Worksheets("mysheetname").Select

To find the last cell with an entry in a column A

Dim cell as range
Set cell = cells(65536,1).end(xlup)

To specify the next blank cell down:
Set cell = cell.offset(1,0)

To copy data from another worksheet in the same workbook to this location:

Worksheets("some other sheet").Range("A1:Z1").Copy cell

or to copy a row from another worksheet:

Worksheets("some other sheet").Rows(5).Copy cell

Bob Flanagan
Macro Systems
http://www.add-ins.com
Productivity add-ins and downloadable books on VB macros for Excel

"Sam Fowler" wrote in message
...
Hi:

Can any one tell me how I would go about selecting a
specific worksheet, then finding the last row with data
in it, selecting the next row and pasting in copied data
from another worksheet.

Thanks,

Sam



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Data Labels- POssible to show data value and data label together? kippers Charts and Charting in Excel 1 April 1st 09 01:33 PM
Increase Your Business By Data Conversion, Data Format and Data EntryServices in India Data Entry India Excel Worksheet Functions 1 March 31st 08 12:51 PM
Save 20% On Data Conversion and Data Formats Services by Data EntryIndia Data Entry India Excel Discussion (Misc queries) 0 March 31st 08 12:00 PM
Data Entry Online, Data Format, Data Conversion and Data EntryServices through Data Entry Outsourcing [email protected] Excel Discussion (Misc queries) 0 March 20th 08 12:45 PM
MULTIPLE DATA - How to insert new data into existing data.... Rodorodo Excel Discussion (Misc queries) 0 December 15th 06 11:50 PM


All times are GMT +1. The time now is 04:03 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"