0

I am trying to perfom a simple task using VBA. I want to assign Range("A1").Value = Range("A1").Value of a different workbook, wich is in a different folder. How do I do that?

I have no idea what to try in order to accomplish this task.

I dont want to open the other file in order to do that, because I am going to loop this procedure for 500 different worksheets.

  • Open the other workbook first, using `Workbooks.Open` as detailed in the linked thread. Then make sure to fully qualify your ranges, `ThisWorkbook.Worksheets("Sheetname").Range("A1").Value = OtherWorkbook.Worksheets("Sheetname").Range("A1").Value` – BigBen Dec 07 '22 at 14:10
  • 1
    If you're not going to open the workbook, then write a formula (can be done using VBA): `='path[Workbook.xlsx]Sheetname'!A1`. – BigBen Dec 07 '22 at 14:31

0 Answers0