I have Office Pro 2003 and am trying to get Access and Excel to play nice but having little luck. In Access I'm using VBA and TransferSpreadsheet to create a new Excel spreadsheet. Now I want to run an Excel macro against that new spreadsheet. Since the spreadsheet created has no macros in it, it appears to me I have to do one of the following:
EITHER
Create the Excel macro (from scratch so to speak) within Access, plop that new macro into the new spreadsheet and then run it (from Access)
OR
FROM ACCESS run an already-written Excel macro (contained in a separate spreadsheet, completely unrelated to the one just created) against the new spreadsheet.
Since I want Access to do this with multiple spreadsheets, I'd prefer the second method above since the new macro wouldn't have to be created multiple times. I just don't know how to do it. Can anyone help?
EITHER
Create the Excel macro (from scratch so to speak) within Access, plop that new macro into the new spreadsheet and then run it (from Access)
OR
FROM ACCESS run an already-written Excel macro (contained in a separate spreadsheet, completely unrelated to the one just created) against the new spreadsheet.
Since I want Access to do this with multiple spreadsheets, I'd prefer the second method above since the new macro wouldn't have to be created multiple times. I just don't know how to do it. Can anyone help?