In the code below, I am trying to open an Excel file from another program and copy a value from it. I managed to get the file to open using the FollowHyperlink command, but I cannot refer to the file to copy anything from it. It seems it doesn't actually open the file until the very end of the Sub. Does anyone know how I can refer to the Excel file I'm trying to open so I can copy a value from it? I would really appreciate some help or tips.
Here is the code to open the file:
ActiveWorkbook.FollowHyperlink Address:="cdb://byname/classname/document/CDB_View/interactive?zeichnung.z_nummer=D00846554&zeichnung.z_index=01"
How can I add to it so that I can copy a value out of it?
This code doesn't work and gives an error:
ActiveWorkbook.FollowHyperlink Address:="cdb://byname/classname/document/CDB_View/interactive?zeichnung.z_nummer=D00846554&zeichnung.z_index=01"
Workbooks("D00846554-01.xlsx").Worksheets("ZACSAANA").Range("A1").Copy ThisWorkbook.Sheets(1).Range("A2")