I have a database that is accessed from both the web and within Notes. Attachments are being created in both areas. I have a button to “Send and Save” within Notes which sends e-mails to the selected parties along with a doc link, with the appropriate title and other information. I can’t seem to get the same process to work from the web side. Any suggestions?
I have a SendTo field, which is a dialog list that allows for user input as well. Tried creating a “WebMailSend” agent to run from a button, but that didn’t work.
Thanks,
Greg
Subject: @MailSend
Have you tried putting an @Mailsend() formula into a computed for computed-for-display field on your form? I will work for both the client and web.
Subject: RE: @MailSend
I have the following in a button. It works for the Notes side…does it need to be in a computer for display field?
@Command([FileSave]) ;
@If(SendTo != “”; @MailSend( sendTo ; copyTo ; blindCopyTo ; “Doc Name” + " - " + ID + " - " + Descrip + " - " + Milestone; remark ; “Internet Users click here:” + " " +“http://Database Name/”+DocID+“?OpenDocument”+ " Notes Users Follow this link - " ; [IncludeDoclink] ) ; " ");
@PostedCommand([FileCloseWindow])
Subject: @MailSend works on web
First, don’t listen to Michael b; he doesn’t know what he’s talking about. @Mailsend works fine on a web form.
The problem with putting @MailSend in a Save button is that user’s don’t HAVE to click the button to save the document. They can just press Ctrl-S or press and respond to the prompt.
If you put the @Mailsend on the form then it will execute regardless of how the doc is saved. But you have to decide WHEN you want the @Mailsend to trigger:
-
If you only want it to trigger when the doc is being saved then include the test @IsDocBeingSaved.
-
If you only want it to trigger when the doc is new then include the test @IsNewDoc.
-
@MailSend returns a 1 when it’s successful. If you only want to send the message once, include it in a computed field and execute it only if the value of the field is not 1.
-
Finally, to prevent multiple messages from being sent on save when fields are still invalid, make the @mailsend field the last field on the form and check Compute after validation.
Subject: RE: @MailSend
Once again, try placing your formula in the WebQuerySave event. The formula on a web page WILL NEVER work!
Subject: Trying to send e-mails from a web document
Create a mailsend agent and use the WebQuerySave event.