I would like to know how I can activate and use macros which are in a excel file already running.
The idea is to generate a event when a mail arrived in my outlook. I filter the subject and call a procedure if it meats a certain criteria.
I know how to open new excel instance and open a file but here my excel file is running already and I have several excel application (each one a different process in the task manager) running. In each excel application I have several excel files open.
I want to use something similar to
Set Xlapp = GetObject(, "Excel.application")
But i want to test if the excel file is runiing in that application or in another one. If it's not in that one, i need to test the seconf application. If no excel application has the file open I will open it but i need to make sure it's not open already.
Then once the file is found, I want to run a macro in that file.
Thanks for your help !