Hi, need some advice on the following in Excel 2007. I progamatically add a module and code to another existing macro-enabled workbook (Book2) and call the procedure from Book1 with
The odd thing is this works corrrectly with some workbooks but not with others. I get an error message saying that the macro may not be available or all macros are disabled. But the original macros in Book2 and the new one added progamatically by Book 1 will all run correctly when run from Book2. I've previously saved Book2 to a different location using:![]()
Please Login or Register to view this content.
where wbTarget is Book2 and BASFilePath & SelectedWB is the path and filename. This works ok for all workbooks.![]()
Please Login or Register to view this content.
Can anyone suggest what the solution might be? Is there a way to programmatically enable all macros in Book2? Thanks in advance
Bookmarks