View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
tryn''''2learn tryn''''2learn is offline
external usenet poster
 
Posts: 10
Default Pulling Data from one spreadsheet to another

Good afternoon, I'm trying to create a macro that at a click of the button will
cause my open spreadsheet to pull data from a closed master spreadsheet.

the length of rows changes daily sometimes 120 others only 50 how do i make
it search until (A) colum shows as blank. Data starts in A2 - CF2 (Row 1 is
headings)

thank you for your help. this is what I've tried with no success.

Sub test()
'
' test Macro
' Macro recorded 5/1/2007 by Allstate
'

'
ChDir _
"D:\documents and settings\ppor2\Desktop\Work
Projects\Pitney\Pitney_Spreadsheet\Original"
Workbooks.Open Filename:= _
"D:\documents and settings\ppor2\Desktop\Work
Projects\Pitney\Pitney_Spreadsheet\Original\Prodda ta_APS1.xls"
Range("A1").Select
Do Until IsEmpty(ActiveCell)
Selection.Copy
Windows("Book1").Activate
Rows("1:1").Select
ActiveSheet.Paste
End Sub