Hi,
I have a number of workbooks - one main file and several templates. In the main file a variable is assigned 'poolID'. Each of the templates is then opened in turn and macros within these templates are run (with Application.Run), however each template uses the same variable. I currently have to put the variable in a cell on the template once it has opened and then reassign the variable in the template based on that cell, then clear the cell contents.
Is there a way to pass the value of the variable which has been assigned in the main file to the variable in the template file in a sort of ByRef or ByVal way?
Sorry if that's not particularly clear - basically I just want poolID in Workbook B to be populated with the value of poolID in Workbook A.
Cheers
I have a number of workbooks - one main file and several templates. In the main file a variable is assigned 'poolID'. Each of the templates is then opened in turn and macros within these templates are run (with Application.Run), however each template uses the same variable. I currently have to put the variable in a cell on the template once it has opened and then reassign the variable in the template based on that cell, then clear the cell contents.
Is there a way to pass the value of the variable which has been assigned in the main file to the variable in the template file in a sort of ByRef or ByVal way?
Sorry if that's not particularly clear - basically I just want poolID in Workbook B to be populated with the value of poolID in Workbook A.
Cheers