I have a mail-in database and I want to run an agent when a new mail doc arrive to this db. I created an agent with trigger "After New Mail Arrives"
I test this agent in Designer->Agent Log and it seems that the agent doesn't run when I send a mail to the address of mail-in database ! Why the agent doesn't run ? My name is listed in all the followings server field:
- Run personal agents
- Run restricted LotusScript/Java agents
- Run unrestricted LotusScript/Java agents
this is the agent code listing:
[/color]
Sub Initialize
Dim session As New notessession
Dim db As notesdatabase
Dim mail As notesdocument
Set db=s.currentdatabase
Set mail = session.DocumentContext
If mail.HasItem( "Id" ) Then
If mail.Id(0)="" Then
mail.ID="No"
mail.save True, True
End If
End Sub