Open template e-mail from protected form

A

Adam

Hi

Word 2003. Forms.

I have a form that once completed will need to be sent to a specific e-mail
address pending the Result of a Drop Down box.

I would also like to take the name and surname that has been entered in to
the form and have it appear in the Subject line of e-mail all with some hard
coded wording.

Is this possible?

Many thanks for any help!
 
J

Jean-Guy Marcil

Adam was telling us:
Adam nous racontait que :
Hi

Word 2003. Forms.

I have a form that once completed will need to be sent to a specific
e-mail address pending the Result of a Drop Down box.

I would also like to take the name and surname that has been entered
in to the form and have it appear in the Subject line of e-mail all
with some hard coded wording.

Is this possible?

Yes, what have you tried?

If nothing yet, start by looking at this, it may be enough...
http://word.mvps.org/faqs/interdev/sendmail.htm
 
A

Adam

Hi Jean-Guy

This looks like a great start and I'm sure I should be to put the
conditional coding together to make it send to the correct email depending on
the selection made from the drop down box.

The part I am now stuck on is making the name that has been entered into the
form appear as the subject of the created e-mail.

Say the fields 'FirstName' and 'Surname' on the form had ben completed with
'Adam' and 'Smith'. How would I get these variables to appear in the Subject
line

With oItem
'Set the recipient for the new email
.To = "(e-mail address removed)"
'Set the recipient for a copy
.CC = "(e-mail address removed)"
'Set the subject
.Subject = "Form for <<FirstName>> <<Surname>>"
'The content of the document is used as the body for the email
.Body = ActiveDocument.Content
.Send
End With

Many thanks
 
J

Jean-Guy Marcil

Adam was telling us:
Adam nous racontait que :
Hi Jean-Guy

This looks like a great start and I'm sure I should be to put the
conditional coding together to make it send to the correct email
depending on the selection made from the drop down box.

The part I am now stuck on is making the name that has been entered
into the form appear as the subject of the created e-mail.

Say the fields 'FirstName' and 'Surname' on the form had ben
completed with 'Adam' and 'Smith'. How would I get these variables
to appear in the Subject line

With oItem
'Set the recipient for the new email
.To = "(e-mail address removed)"
'Set the recipient for a copy
.CC = "(e-mail address removed)"
'Set the subject
.Subject = "Form for <<FirstName>> <<Surname>>"
'The content of the document is used as the body for the email
.Body = ActiveDocument.Content
.Send
End With

Something like this:

.Subject = "Form for " & ActiveDocument.FormFields("FirstName").Result _
& " " & ActiveDocument.FormFields("Surname").Result
 

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