value transfer between files

  • Thread starter Thread starter JIM.H.
  • Start date Start date
J

JIM.H.

Hello,
I use the following line in a loop in my code to copy
values from a sheet to another.

Sheets(desSheetName).Cells(curDesRow, 1).Value = Sheets
(srcSheetName).Cells(curSrcRow, 1).Value

This is working in the same file, can I do the same thing
in two different file? Or is ther any other way?
Thanks,
Jim.
 
Workbooks("Bk2.xls").Sheets(desSheetName).Cells(curDesRow, 1).Value = _
Workbooks("Bk1.xls").Sheets(srcSheetName).Cells(curSrcRow, 1).Value
 

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

Back
Top