CDO Email Syntax Question

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • JNariss@gmail.com

    #1

    CDO Email Syntax Question

    Hello,

    I finally figured out how to get my form to its database and have an
    email come my way. However I am now trying to set up the body of the
    email to include the form details. However the body of the email that
    is sent only includes the last line of the "body" tag and has no
    details next to it.

    The email sent shows up with this in its body:

    Request Date:


    AND NOTHING ELSE.

    The script/code I am using is:

    <%
    Set objMessage = CreateObject("C DO.Message")
    objMessage.Subj ect = "New Form"
    objMessage.Send er = "Intranet"
    objMessage.To = "justine.nariss @egseg.com"
    objMessage.Text Body="An IT Employee Status Change form has been filled
    out. Please see the information below: " & VbCrLf
    objMessage.Text Body="Employee Name: " & Request.Form("E mployeeName") &
    VbCrLf
    objMessage.Text Body="Pay Number: " & Request.Form("P ayNumber") & VbCrLF
    objMessage.Text Body="Requested By: " & Request.Form("R equestedBy") &
    VbCrLF
    objMessage.Text Body="Request Date: " & Request.Form("R equestDate")

    objMessage.Conf iguration.Field s.Item("http://schemas.microso ft.com/cdo/configuration/sendusing")
    = 2
    objMessage.Conf iguration.Field s.Item("http://schemas.microso ft.com/cdo/configuration/smtpserver")
    = "155.116.12 .19"
    objMessage.Conf iguration.Field s.Item("http://schemas.microso ft.com/cdo/configuration/smtpserverport" )
    = 25
    objMessage.Conf iguration.Field s.Update

    objMessage.Send
    %>


    As you can see from above I am trying to get the body of the email to
    look like this:


    An IT Employee Status Change form has been filled out. Please see the
    information below:

    Employee Name: Someones Name
    Pay Number: XX333
    Requested By: Someones Name
    Request Date: mm/dd/yy



    All the above fields are the fields to my form that users will be
    filling out.
    Any help would be greatly appreciated.

    Thanks,
    Justine

  • Herfried K. Wagner [MVP]

    #2
    Re: CDO Email Syntax Question

    <JNariss@gmail. com> schrieb:[color=blue]
    > I finally figured out how to get my form to its database and have an
    > email come my way. However I am now trying to set up the body of the
    > email to include the form details. However the body of the email that
    > is sent only includes the last line of the "body" tag and has no
    > details next to it.[/color]

    Your question seems to be related to Classic ASP. I suggest to ask it at
    "microsoft.publ ic.inetserver.a sp.general".

    --
    M S Herfried K. Wagner
    M V P <URL:http://dotnet.mvps.org/>
    V B <URL:http://classicvb.org/petition/>

    Comment

    Working...