I have an Excel worksheet that uses external data sources, which means they're disabled on open and I have to dismiss two annoying banners. I can (relatively) easily automate this stupidity away with KM, but what I'd really like to do is have the macro run on document open.
Note that the macro should not run when the document becomes active (i.e. it was already open and I just switched to it), but only on initial open.
I can, of course, get around all of this by having the macro open the file as the first step, but I often open the file by double-clicking in Finder...I'd have to retrain myself to run the macro instead.
I thought about that one, but then the macro would launch every time the window came to the foreground. I need this to run when it first opens, but after that, it'd fail (because the banners aren't there).
I guess if it failed silently, that wouldn't be too bad.
It's a worksheet with some stock prices in it; I open and close it multiple times a day. There's nothing that really runs, but it won't update until you manually remove a couple warnings. I think I'll just write the macro and invoke it manually; it'll still save a bunch of mouse move-and-click action.
I did eventually get it working, using a "find image" check. But it then always running, silently launching and stopping if the image isn't found. In the end, I went back to a hot key that I press after opening the file—it gets rid of the banners and does a refresh on the external data source. Works well enough—one hot key vs. a fair bit of mouse moving.