Overwriting data during transfer [Solved]

Posts
8
Registration date
Friday June 15, 2018
Last seen
July 5, 2018
-
Sir,
I had created vba code to transfer data from one workbook to another. it's working 1st time . but second time when I'm tapping the command button to transfer data it is overwriting the previous saved data. I want that when tap on command button it should submit data in the next empty row during each transfer.
Please help me for this problem.
See more 

Your reply

2 replies

Best answer
Posts
10909
Registration date
Monday June 3, 2013
Status
Moderator
Last seen
December 7, 2018
1
Thank you
Add 1 to the variable if the variable is greater than 1!

Thank you, ac3mark 1

Glad we were able to help! Love us? Write us a review! Rate CCM

CCM has helped 2562 users this month

Respond to ac3mark
Posts
2435
Registration date
Sunday September 12, 2010
Status
Moderator
Last seen
December 4, 2018
1
Thank you
Hi Mukul,

To find the first available row:
Dim lRow as integer
lRow=Range("A"&rows.count).end(xlup).offset(1,0).row

Best regards,
Trowa

Thank you, TrowaD 1

Glad we were able to help! Love us? Write us a review! Rate CCM

CCM has helped 2562 users this month

MUKUL_1308
Posts
8
Registration date
Friday June 15, 2018
Last seen
July 5, 2018
-
Thank you so much Sir !
now it is working perfectly.
thanks a lot.
Respond to TrowaD