I am trying to run a macro that lives in workbook B from within a macro in workbook A.
I was looking at this post. However, the difference is that my workbook is a workbook object...
'Declare workbook objects
Dim AssociateTemplateFile As Workbook
Dim AssociateTemplateName As String
Set AssociateTemplateFile = Workbooks.Open(RootPath & AssociateTemplateName)
This means I loose the ability to encase the name within ' ':
Application.Run "'AssociateTemplateFile' !AddDataValidation"
Doesn't work. I tried several iterations, with the variable, the file, but nothing seems to be working.
Any suggestions on how to get this going? I can always force run the macro to run when the other workbook is open, but I prefer to have the control in the main file if possible...