Chris,
It helps if you use reply - that way the previous message(s) are kept in the
current message making it
easier to track what has been said before.
Let's say that the information is on Sheet1 (replace with the name of your
sheet)
Your data is ordered like this, with all the info on row 2
A B C D
Date Inv No Amount Salesman
23/07/05 3 £20.00 Bart
And Sheet2 is laid out in a similar way.
Than use this code before you clear the invoice sheet:
================================================== =======
Dim lrw as Long, cl as Long
' this gets the first open row on sheet2
lrw = Sheets("Sheet2").= Cells(Rows.COUNT, "A").End(xlUp).Offset(1, 0).Row
For cl = 1 to 4 ' cycle through the 4 columns, trans
each cell
Sheets("Sheet2").Cells(lrw,cl)=Sheets("Sheet1").Ce lls(2,cl)
Next
================================================
If the data is scattered:
Date in A5
Inv No in D25
Amount in T15
Salesman in C18
than use:
======================================
Dim lrw as Long, cl as Long
' this gets the first open row on sheet2
lrw = Sheets("Sheet2").= Cells(Rows.COUNT, "A").End(xlUp).Offset(1, 0).Row
Sheets("Sheet2").Cells(lrw,1)=Sheets("Sheet1").Ran ge("A5")
Sheets("Sheet2").Cells(lrw,2)=Sheets("Sheet1").Ran ge("D25")
Sheets("Sheet2").Cells(lrw,3)=Sheets("Sheet1").Ran ge("T15")
Sheets("Sheet2").Cells(lrw,4)=Sheets("Sheet1").Ran ge("C18")
============================================
Let me know if you need any further explanation or help....
Note that using Cells() is similar to using Range()
where Cells(r,c) = the range where row # = r and column position = c
(A=1,B=2,C=3,..............)
--
steveB
Remove "AYN" from email to respond
"chris100" wrote in
message ...
Hi Steve,
Could you do me a big favour and give a simple example of the code you
mentioned for say just sheet 1 and sheet 2. I'm not very experienced as
you know but an example would help me to play around a bit so i can
piece together how it works.
Regards,
Chris
--
chris100
------------------------------------------------------------------------
chris100's Profile:
http://www.excelforum.com/member.php...o&userid=25166
View this thread: http://www.excelforum.com/showthread...hreadid=389755