Macro Help

  • Thread starter Thread starter Larry Fish via OfficeKB.com
  • Start date Start date
L

Larry Fish via OfficeKB.com

' Macro1 Macro
This macro works except I need to be able to find a blank cell in column C.
The first time I run the Macro it works. The second time it copies over the
first entry not the cell below it. I am not sure how to change "Range(c9).
select"
Please see macro below

Thanks for the help

' Macro recorded 9/25/2006 by
'
' Keyboard Shortcut: Ctrl+a
'
Range("C1:G1").Select
Selection.Copy
'
Range("A1").Select
Selection.End(xlDown).Select
Range("C65536").Select
Selection.End(xlUp).Select
Range("C9").Select
ActiveSheet.Paste
End Sub
 
Try:

Sub test()
Range("C1:G1").Copy Range("C65536").End(xlUp).Offset(1, 0)
End Sub

You should be able to run that as often as you want provided there is
something in cell C1

Regards

Trevor
 
Think that needs to be:

Range("C1:G1").Copy Cells(Rows.Count, "c").End(xlUp).Offset(1, 0)

Regards

Trevor


Don Guillett said:
try
sub copyit()
Range("C1:G1").Copy cells(rows.count,"c").end(xlup).row+1
end sub
 
Sorry.
Or what I really meant

Sub copyit()
Range("C1:G1").Copy _
Cells(Cells(Rows.Count, "c").End(xlUp).Row + 1, "c")
End Sub

--
Don Guillett
SalesAid Software
(e-mail address removed)
Trevor Shuttleworth said:
Think that needs to be:

Range("C1:G1").Copy Cells(Rows.Count, "c").End(xlUp).Offset(1, 0)

Regards

Trevor
 
Don, I gget a syntex Error in the row that starts with Cells.

Thanks
Larry

Trevor said:
Try:

Sub test()
Range("C1:G1").Copy Range("C65536").End(xlUp).Offset(1, 0)
End Sub

You should be able to run that as often as you want provided there is
something in cell C1

Regards

Trevor
' Macro1 Macro
This macro works except I need to be able to find a blank cell in column
[quoted text clipped - 22 lines]
ActiveSheet.Paste
End Sub
 
Trevor, I ran it and it works great!!
Thanks so much for your time and help

Larry said:
Don, I get a syntax Error in the row that starts with Cells.

Thanks so much for your time and help
Larry
[quoted text clipped - 14 lines]
 
Back
Top