<% Const cdoSendUsingMethod = _ "http://schemas.microsoft.com/cdo/configuration/sendusing" Const cdoSendUsingPort = 2 Const cdoSMTPServer = _ "http://schemas.microsoft.com/cdo/configuration/smtpserver" Const cdoSMTPServerPort = _ "http://schemas.microsoft.com/cdo/configuration/smtpserverport" Const cdoSMTPConnectionTimeout = _ "http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout" Const cdoSMTPAuthenticate = _ "http://schemas.microsoft.com/cdo/configuration/smtpauthenticate" Const cdoBasic = 1 Const cdoSendUserName = _ "http://schemas.microsoft.com/cdo/configuration/sendusername" Const cdoSendPassword = _ "http://schemas.microsoft.com/cdo/configuration/sendpassword" Dim objConfig ' As CDO.Configuration Dim objMessage ' As CDO.Message Dim Fields ' As ADODB.Fields ' Get a handle on the config object and it's fields Set objConfig = Server.CreateObject("CDO.Configuration") Set Fields = objConfig.Fields ' Set config fields we care about With Fields .Item(cdoSendUsingMethod) = cdoSendUsingPort .Item(cdoSMTPServer) = "smtp.lota.net" .Item(cdoSMTPServerPort) = 25 .Item(cdoSMTPConnectionTimeout) = 10 '.Item(cdoSMTPAuthenticate) = cdoBasic '.Item(cdoSendUserName) = "username" '.Item(cdoSendPassword) = "password" .Update End With Set objMessage = Server.CreateObject("CDO.Message") Set objMessage.Configuration = objConfig BodyText = "Customer Information" & vbcrlf BodyText = BodyText & "Company Name: " & request.form("company_name") & vbcrlf BodyText = BodyText & "Contact Person: " & request.form("contact_person") & vbcrlf BodyText = BodyText & "Title: " & request.form("title") & vbcrlf BodyText = BodyText & "Business Nature: " & request.form("business_nature") & vbcrlf BodyText = BodyText & "Address: " & request.form("address") & vbcrlf BodyText = BodyText & "Country: " & request.form("country") & vbcrlf BodyText = BodyText & "Email: " & request.form("email") & vbcrlf BodyText = BodyText & "Tel: " & request.form("tel") & vbcrlf BodyText = BodyText & "Fax: " & request.form("fax") & vbcrlf & vbcrlf BodyText = BodyText & "Product Enquiry" & vbcrlf BodyText = BodyText & "Model No:" & request.form("model_no1") & " -Qty:" & request.form("qty_no1") & vbcrlf BodyText = BodyText & "Model No:" & request.form("model_no2") & " -Qty:" & request.form("qty_no2") & vbcrlf BodyText = BodyText & "Model No:" & request.form("model_no3") & " -Qty:" & request.form("qty_no3") & vbcrlf BodyText = BodyText & "Model No:" & request.form("model_no4") & " -Qty:" & request.form("qty_no4") & vbcrlf BodyText = BodyText & "Model No:" & request.form("model_no5") & " -Qty:" & request.form("qty_no5") & vbcrlf & vbcrlf BodyText = BodyText & "Sample Delivery Term" & vbCrLf BodyText = BodyText & "Courier: " & request.form("courier") & vbcrlf BodyText = BodyText & "Account: " & Request.form("account") & vbcrlf BodyText = BodyText & "Message to Chartrick: " & request.form("message_to_chartrick") & vbcrlf With objMessage .To = "saleshk@chartrick.com" .From = "saleshk@chartrick.com" .Subject = "Enquiry from the web site" '.TextBody = "SMTP Relay Test Sent @ " & Now() .TextBody = BodyText .Send End With Set Fields = Nothing Set objMessage = Nothing Set objConfig = Nothing response.redirect ("thankyou1.htm") %>