PC Review


Reply
 
 
Mark J
Guest
Posts: n/a
 
      3rd Oct 2008
I have a spreadsheet that i need to add data from another spreadsheet daily.
Is there a way using vb that i can copy data from one spreadsheet to another,
but have the data go to the last row..

ie if i copy data to the first 20 rows, then the next day i need to copy new
data starting at row 21, and so forth each day.

I would really like to do this using vba. Thanks
 
Reply With Quote
 
 
 
 
Chip Pearson
Guest
Posts: n/a
 
      3rd Oct 2008
Try something along the lines of the following:

Sub AAA()
Dim WB1 As Workbook
Dim WB2 As Workbook
Dim LastRow As Long
Set WB1 = Workbooks("FromBook.xls") ' source workbook
Set WB2 = Workbooks("ToWorkbook.xls") ' destination workbook
' change destination sheet name below
With WB2.Worksheets("SheetName")
' change column letter below
LastRow = .Cells(.Rows.Count, "C").End(xlUp)(2, 1).Row
' change source sheet name and row number
WB1.Worksheets("FromSheet").Rows(100).Copy _
Destination:=.Cells(LastRow, "A")
End With
End Sub

Cordially,
Chip Pearson
Microsoft MVP
Excel Product Group
Pearson Software Consulting, LLC
www.cpearson.com
The San Diego Project Group, LLC
(email is on the web site)
USA Central Daylight Time (-5:00 GMT)


On Fri, 3 Oct 2008 08:49:03 -0700, Mark J
<(E-Mail Removed)> wrote:

>I have a spreadsheet that i need to add data from another spreadsheet daily.
>Is there a way using vb that i can copy data from one spreadsheet to another,
>but have the data go to the last row..
>
>ie if i copy data to the first 20 rows, then the next day i need to copy new
>data starting at row 21, and so forth each day.
>
>I would really like to do this using vba. Thanks

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Using PC mover opalocka Windows Vista Performance 2 31st Dec 2008 01:09 PM
laplink pc mover aaronep@pacbell.net Windows XP Help 4 10th Jul 2007 10:11 PM
C# mover Andy Summers Microsoft C# .NET 6 9th Jun 2007 07:55 AM
File Mover jo Freeware 0 8th Jul 2004 01:40 PM
Application Mover Seek Freeware 20 14th Oct 2003 05:37 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:14 AM.