I have a scheduled BO task that runs daily on an NT server.
It opens BO, passes in the user id and password, turns off the splash screen etc.
-user USERID -pass PASSWORD -nologo
(put that after the "C:\...BUSOBJ.EXE", and before the "C:\path to your report"
When my report opens, it refreshes, saves, exports, etc, and kicks off a series of other reports and does the same to them.
The big thing with the DOCUMENT_OPEN I found, is that in order to get back into the report to modify it, you have to go in and turn the 'warn me about documents with macros'. And because it has this, you always have to make sure you turn that OFF again or it will just sit there waiting for you to answer it when it goes to run from your scheduler.
For me it's not a big deal. I do have some reports that kick off code when they're openeed as well. (Not scheduled.)Some of our users get confused and panic when it warns them that the document has macros, because of viruses, etc., and end up clicking disable macros... then of course your code doesn't run.
After a user checks don't always ask, and clicks enable macros, they should only get that once. BUT when you make a change to a report, it goes back to asking the macro question before a user can open it. I've tried just changing it in the tools menu, but it seems to store that info at the user level somehow.
Anyone... can he/we get around this?
Good luck.
ainkca