Hi,
I need help with an agent. The agent runs fine when triggered manually, but when scheduled, it does not run. I can see from the agent log that it did initialize, but it seems like it did not select the documents. The target is “select all documents in database”
The lotusscript code are as follows:
‘set view
Set view= db.GetView(“Number”)
‘Set doc
Set doc1 = view.GetFirstDocument
Do Until doc1 Is Nothing
Blah blah
What am I doing wrong here. I am working with back-end. Is my target setting incorrect. Again, manually running the agent works fine. I cannot see it being a permissions issue?
Any suggestions?
Regards
Bafie
Subject: Sceduled agent not running
I had exactly the same problem - several weeks later it was discovered that a tick box on the db properties disabled the running of background agents. Removed it and all was well again.
Subject: RE: Sceduled agent not running
Good thought…But it is not selected
Subject: RE: Sceduled agent not running
Run ‘test’ diagnostic. It often gives you a good clue.
Subject: RE: Sceduled agent not running
Then you need to determine access rights, make sure the server can see the docs (maybe hidden by reader field). I read somewhere that if you put @Prompt in the server agent you can see what is happening on the server console, apparently, @prompt write to the server console making it easy to watch variables etc.
Subject: Sceduled agent not running
What does the agent log say? What does the server log say? It is hard to tell from the description whether the agent actually started running or not. Add some print or msgbox statements to add messages to ther server’s log. If it will not run at all, you probably have a UI (front-end) object in the code. You should see an error in the log. Your example shows a snippet of code – I assume you are setting the NotesDatabase and other objects as well?
Subject: RE: Sceduled agent not running
Hi Doug,
No, I am not accessing any front-end UI classes.
I think that I may have found the problem.
On the agent manager on the server the MAX Lotusscript/Java execution time was set at 15 minute. I changed the setting and hope that it will resolve the issue.
The agent log shows that the agent started and that x number of documents were selected, but did not provide more detail.
I guess I will find out tomorrow.
Cheers
Bafie