Send E-mail

H

Help Me

I am trying to have infopath send the form via e-mail

I have the following code working:

var oEnvelope = XDocument.View.Window.MailEnvelope;

oEnvelope.To = rgRecipients.join("; ");
oEnvelope.Subject = getNodeValue(xmlTitle);
oEnvelope.Visible = true

But this just changes the view to an outlook e-mail view. I actually want
it to send the e-mail. i tried oEnvelop.Send but it didn't work. Does
anyone know the code?

Thanks
 
A

Andrew Watt [MVP - InfoPath]

I am trying to have infopath send the form via e-mail

I have the following code working:

var oEnvelope = XDocument.View.Window.MailEnvelope;

oEnvelope.To = rgRecipients.join("; ");
oEnvelope.Subject = getNodeValue(xmlTitle);
oEnvelope.Visible = true

But this just changes the view to an outlook e-mail view. I actually want
it to send the e-mail. i tried oEnvelop.Send but it didn't work. Does
anyone know the code?

Thanks

Nobody knows the code. :)

This is my understanding of the situation.

The reason is that for security reasons InfoPath shouldn't send emails
from, say, my email address without me (a human being) taking the
final decision about whether to send it or not.

Without that "reality check" any coder could take what you have done a
malign step further.

If the user wants/needs to send the form data in an email it isn't a
huge ask to click Send. If the user hadn't intended to send an email,
and decided that he/she didn't want to then it's a useful check.

Andrew Watt
MVP - InfoPath
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top