Find last row in column and past below

W

winnie123

Sorry I am asking for help again.

Been working on this most of the day now and can not get it figured, I am
sure it will be something simple but just keep going round in circles.

I am trying to copy a range A4:B4 to a different worksheet just below the
current last row of data. code below

Sheets("Temp").Select
Range("A4:B4").Copy
Sheets("CustomerLogSheet").Select
Range("A1" & Lrow + 1).PasteSpecial

It does not give me an error, but it copies and overwrites data already in
sheet.

I have tried to debug and Range("A1" & Lrow + 1) equals 4

So I end up with the same amount rowss previously but with one record missing.

In the Colum A I have a value in Row 1, then Row 2 is Blank, then Row 3
until the last row has data.

I tried putting a value in Row 2 but it does not seem to make any difference

Thanks

Winnie
 
P

Per Jessen

Hi Winnie

Look at this:

LastRow = Sheets("CustomerLogSheet").Range("A" & Rows.Count).End
(xlUp).Row

Sheets("Temp").Range("A4:B4").Copy
Sheets("CustomerLogSheet").Range("A" & LastRow + 1).PasteSpecial
(xlValues)
Application.CutCopyMode = False


Regards,
Per
 
W

winnie123

Thank again Per, for the second time today.

it has worked and hopefully tonight I will finish my project.

I wonder will I ever get the hang of this but I guess unless I ask for help
I never will.

The next best thing to knowing something is knowing where to find it.

Thanks
Winnie
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top