Is it possible using the smtp class in asp.net to send emails and
authenticate to the mail server that is sending the emails out.
Currently I have a web application that works fine on my machine, will send
email to both my company email addresses and to non-company email addresses.
However, as soon as I move the app into the production server it does not
send email to non company email addresses. What I mean by company is our
domain could @domain.com and it will work fine sending emails to any one
with that email address, but anyone without that in their email address and
it crashes. Any help on this would be appreciated.
--
J. D 11 2027
Private Sub Command1_Click( )
Dim Mail As CDO.Message
Dim Conf As CDO.Configurati on
Set Mail = New CDO.Message
Set Conf = New CDO.Configurati on
With Conf
.Fields("http://schemas.microso ft.com/cdo/configuration/sendusing")
= CDO.CdoSendUsin g.cdoSendUsingP ort
.Fields("http://schemas.microso ft.com/cdo/configuration/smtpserver")
= "your_mail_serv er_here"
.Fields("http://schemas.microso ft.com/cdo/configuration/smtpserverport" )
= 25
.Fields.Add("ht tp://schemas.microso ft.com/cdo/configuration/smtpauthenticat e",
"1") 'basic authentication
.Fields.Add("ht tp://schemas.microso ft.com/cdo/configuration/sendusername",
"my_username_he re") 'set your username here
.Fields.Add("ht tp://schemas.microso ft.com/cdo/configuration/sendpassword",
"super_secr et") 'set your password here
End With
With Mail
.Configuration = Conf
.From = "your_email_add r"
.To = "target_email_a ddr"
.Subject = "Testing"
.HTMLBody = "As title"
.Sender = "your_email_add r"
.Send
End With
End Sub
"JD" <jd****@dalys.u s> Ľ¶Ľg©ó¶lĄó·s»D: uC************* *@TK2MSFTNGP15. phx.gbl... Is it possible using the smtp class in asp.net to send emails and authenticate to the mail server that is sending the emails out.
Currently I have a web application that works fine on my machine, will send email to both my company email addresses and to non-company email addresses. However, as soon as I move the app into the production server it does not send email to non company email addresses. What I mean by company is our domain could @domain.com and it will work fine sending emails to any one with that email address, but anyone without that in their email address and it crashes. Any help on this would be appreciated.
-- J. D
Lau Lei
Thanks for the quick reply, my bad for not pointing this out but this
was using asp.net and not visual basic.
See code down below
'Put user code to initialize the page here
Dim oMail As System.Web.Mail .SmtpMail
Dim oMailMsg As New System.Web.Mail .MailMessage
Dim sServer As String
Dim sMsgBody As New System.Text.Str ingBuilder
Dim sAutoMsgBody As New System.Text.Str ingBuilder
Try
'Check to see if there is any postback, if there is none
then send the message
If Not IsPostBack Then
With oMail
'Set the mail server name
.SmtpServer =
ConfigurationSe ttings.AppSetti ngs("SmtpServer ")
'Get the name of the server that this resides on
sServer = Request.ServerV ariables("SERVE R_NAME")
With oMailMsg
'Set the body format
.BodyFormat = Mail.MailFormat .Html
'Set the body content
With sMsgBody
.Append("Form Name:" &
Request.Form("F ormName") & "<br>")
.Append("<br>")
.Append("First Name: " &
Request.Form("F irstName") & "<br>")
End With
.Body = sMsgBody.ToStri ng() & vbCrLf & "Server:
" & sServer
''Automate response email
'With sAutoMsgBody
' .Append("<p>bla h blah</p>")
' .Append("<br>")
'End With
'With oMailMsg
' 'Take it from the email address that was
entered on the contact form
' .To = Request.Form("e mail")
' 'Set the body format
' .BodyFormat = Mail.MailFormat .Html
' 'Subject line
' .Subject = "Automated response"
' 'From address
' .From =
ConfigurationSe ttings.AppSetti ngs("CustFromSi te")
' 'Body
' .Body = sAutoMsgBody.To String()
'End With
''Send the email
'.Send(oMailMsg )
End With
'Clean up
oMail = Nothing
oMailMsg = Nothing
sMsgBody = Nothing
'Check to see if this is going to a custom thank you
page or not
If Len(Request.For m("RedirectPath ")) > 0 Then
'Redirect the site to the custom thank you page
Response.Redire ct(Request.Form ("RedirectPath" ))
End If
End If
Catch ex As Exception
'To be done yet
Response.Write( ex.Message)
Response.Write( ex.StackTrace)
End Try
--
Sent via .NET Newsgroups http://www.dotnetnewsgroups.com
It doesn't really matter.
First of all you should know System.Web.Mail is just a wrapper over CDO
objects.
And then MailMessage also have property called "Fields" that you can use.
Just use the field names in the example to fill in the information.
"JD" <wo**@dalyse.us > ???????:eY***** *********@TK2MS FTNGP09.phx.gbl ... Lau Lei
Thanks for the quick reply, my bad for not pointing this out but this was using asp.net and not visual basic.
See code down below
'Put user code to initialize the page here Dim oMail As System.Web.Mail .SmtpMail Dim oMailMsg As New System.Web.Mail .MailMessage Dim sServer As String Dim sMsgBody As New System.Text.Str ingBuilder Dim sAutoMsgBody As New System.Text.Str ingBuilder
Try
'Check to see if there is any postback, if there is none then send the message If Not IsPostBack Then With oMail 'Set the mail server name .SmtpServer = ConfigurationSe ttings.AppSetti ngs("SmtpServer ")
'Get the name of the server that this resides on sServer = Request.ServerV ariables("SERVE R_NAME") With oMailMsg
'Set the body format .BodyFormat = Mail.MailFormat .Html 'Set the body content With sMsgBody .Append("Form Name:" & Request.Form("F ormName") & "<br>") .Append("<br>") .Append("First Name: " & Request.Form("F irstName") & "<br>") End With
.Body = sMsgBody.ToStri ng() & vbCrLf & "Server: " & sServer
''Automate response email 'With sAutoMsgBody ' .Append("<p>bla h blah</p>") ' .Append("<br>") 'End With
'With oMailMsg ' 'Take it from the email address that was entered on the contact form ' .To = Request.Form("e mail") ' 'Set the body format ' .BodyFormat = Mail.MailFormat .Html ' 'Subject line ' .Subject = "Automated response" ' 'From address ' .From = ConfigurationSe ttings.AppSetti ngs("CustFromSi te") ' 'Body ' .Body = sAutoMsgBody.To String() 'End With ''Send the email '.Send(oMailMsg )
End With 'Clean up oMail = Nothing oMailMsg = Nothing sMsgBody = Nothing 'Check to see if this is going to a custom thank you page or not If Len(Request.For m("RedirectPath ")) > 0 Then 'Redirect the site to the custom thank you page Response.Redire ct(Request.Form ("RedirectPath" )) End If
End If Catch ex As Exception 'To be done yet Response.Write( ex.Message) Response.Write( ex.StackTrace)
End Try
-- Sent via .NET Newsgroups http://www.dotnetnewsgroups.com
JD,
I think the problem is : The production server requires authentication
before you can send a mail using a specific email Id.
In ASP .Net there is no direct way to achieve this, so the solution Lau has
suggested can be implemented in ASP .Net by adding a reference to the COM
object.
"JD" wrote: Lau Lei
Thanks for the quick reply, my bad for not pointing this out but this was using asp.net and not visual basic.
See code down below
'Put user code to initialize the page here Dim oMail As System.Web.Mail .SmtpMail Dim oMailMsg As New System.Web.Mail .MailMessage Dim sServer As String Dim sMsgBody As New System.Text.Str ingBuilder Dim sAutoMsgBody As New System.Text.Str ingBuilder
Try
'Check to see if there is any postback, if there is none then send the message If Not IsPostBack Then With oMail 'Set the mail server name .SmtpServer = ConfigurationSe ttings.AppSetti ngs("SmtpServer ")
'Get the name of the server that this resides on sServer = Request.ServerV ariables("SERVE R_NAME") With oMailMsg
'Set the body format .BodyFormat = Mail.MailFormat .Html 'Set the body content With sMsgBody .Append("Form Name:" & Request.Form("F ormName") & "<br>") .Append("<br>") .Append("First Name: " & Request.Form("F irstName") & "<br>") End With
.Body = sMsgBody.ToStri ng() & vbCrLf & "Server: " & sServer
''Automate response email 'With sAutoMsgBody ' .Append("<p>bla h blah</p>") ' .Append("<br>") 'End With
'With oMailMsg ' 'Take it from the email address that was entered on the contact form ' .To = Request.Form("e mail") ' 'Set the body format ' .BodyFormat = Mail.MailFormat .Html ' 'Subject line ' .Subject = "Automated response" ' 'From address ' .From = ConfigurationSe ttings.AppSetti ngs("CustFromSi te") ' 'Body ' .Body = sAutoMsgBody.To String() 'End With ''Send the email '.Send(oMailMsg )
End With 'Clean up oMail = Nothing oMailMsg = Nothing sMsgBody = Nothing 'Check to see if this is going to a custom thank you page or not If Len(Request.For m("RedirectPath ")) > 0 Then 'Redirect the site to the custom thank you page Response.Redire ct(Request.Form ("RedirectPath" )) End If
End If Catch ex As Exception 'To be done yet Response.Write( ex.Message) Response.Write( ex.StackTrace)
End Try
-- Sent via .NET Newsgroups http://www.dotnetnewsgroups.com
Okay, could you give me an example of how it would look, I am trying and I
am getting some weird looking results.
CDO.CdoSendUsin g.cdoSendUsingP ort - Where does this come from?
.Fields("http://schemas.microso ft.com/cdo/configuration/sendusing")
= CDO.CdoSendUsin g.cdoSendUsingP ort
.Fields("http://schemas.microso ft.com/cdo/configuration/smtpserver")
= "your_mail_serv er_here"
.Fields("http://schemas.microso ft.com/cdo/configuration/smtpserverport" )
= 25
.Fields.Add("ht tp://schemas.microso ft.com/cdo/configuration/smtpauthenticat e",
"1") 'basic authentication
.Fields.Add("ht tp://schemas.microso ft.com/cdo/configuration/sendusername",
"my_username_he re") 'set your username here
.Fields.Add("ht tp://schemas.microso ft.com/cdo/configuration/sendpassword",
"super_secr et") 'set your password here
"Lau Lei Cheong" <le****@yehoo.c om.hk> wrote in message
news:OW******** ******@tk2msftn gp13.phx.gbl... It doesn't really matter.
First of all you should know System.Web.Mail is just a wrapper over CDO objects.
And then MailMessage also have property called "Fields" that you can use.
Just use the field names in the example to fill in the information.
"JD" <wo**@dalyse.us > ???????:eY***** *********@TK2MS FTNGP09.phx.gbl ... Lau Lei
Thanks for the quick reply, my bad for not pointing this out but this was using asp.net and not visual basic.
See code down below
'Put user code to initialize the page here Dim oMail As System.Web.Mail .SmtpMail Dim oMailMsg As New System.Web.Mail .MailMessage Dim sServer As String Dim sMsgBody As New System.Text.Str ingBuilder Dim sAutoMsgBody As New System.Text.Str ingBuilder
Try
'Check to see if there is any postback, if there is none then send the message If Not IsPostBack Then With oMail 'Set the mail server name .SmtpServer = ConfigurationSe ttings.AppSetti ngs("SmtpServer ")
'Get the name of the server that this resides on sServer = Request.ServerV ariables("SERVE R_NAME") With oMailMsg
'Set the body format .BodyFormat = Mail.MailFormat .Html 'Set the body content With sMsgBody .Append("Form Name:" & Request.Form("F ormName") & "<br>") .Append("<br>") .Append("First Name: " & Request.Form("F irstName") & "<br>") End With
.Body = sMsgBody.ToStri ng() & vbCrLf & "Server: " & sServer
''Automate response email 'With sAutoMsgBody ' .Append("<p>bla h blah</p>") ' .Append("<br>") 'End With
'With oMailMsg ' 'Take it from the email address that was entered on the contact form ' .To = Request.Form("e mail") ' 'Set the body format ' .BodyFormat = Mail.MailFormat .Html ' 'Subject line ' .Subject = "Automated response" ' 'From address ' .From = ConfigurationSe ttings.AppSetti ngs("CustFromSi te") ' 'Body ' .Body = sAutoMsgBody.To String() 'End With ''Send the email '.Send(oMailMsg )
End With 'Clean up oMail = Nothing oMailMsg = Nothing sMsgBody = Nothing 'Check to see if this is going to a custom thank you page or not If Len(Request.For m("RedirectPath ")) > 0 Then 'Redirect the site to the custom thank you page Response.Redire ct(Request.Form ("RedirectPath" )) End If
End If Catch ex As Exception 'To be done yet Response.Write( ex.Message) Response.Write( ex.StackTrace)
End Try
-- Sent via .NET Newsgroups http://www.dotnetnewsgroups.com
It would seem that you may be right
..Fields("http://schemas.microso ft.com/cdo/configuration/sendusing") = 2
..Fields("http://schemas.microso ft.com/cdo/configuration/smtpserver").va lues
= "mail.nemo. com"
..Fields("http://schemas.microso ft.com/cdo/configuration/smtpserverport" ).values
= 25
..Fields.Add("h ttp://schemas.microso ft.com/cdo/configuration/smtpauthenticat e",
"1") 'basic authentication
..Fields.Add("h ttp://schemas.microso ft.com/cdo/configuration/sendusername",
"crush") 'set your username here
..Fields.Add("h ttp://schemas.microso ft.com/cdo/configuration/sendpassword",
"totallydud e") 'set your password here
it fails on the first line above and I get the error message down below
Object variable or With block variable not set. at
Microsoft.Visua lBasic.Compiler Services.LateBi nding.InternalL ateSet(Object o,
Type& objType, String name, Object[] args, String[] paramnames, Boolean
OptimisticSet, CallType UseCallType) at
Microsoft.Visua lBasic.Compiler Services.LateBi nding.LateSetCo mplex(Object o,
Type objType, String name, Object[] args, String[] paramnames, Boolean
OptimisticSet, Boolean RValueBase) at
blueconnect.sen dmail.Page_PreR ender(Object sender, EventArgs e) in
C:\projects\Doc root\OtherClien ts\jci\app_incl udes\sendmail.a spx.vb:line 49
"Mayur Shah" <Mayur Sh**@discussion s.microsoft.com> wrote in message
news:6C******** *************** ***********@mic rosoft.com... JD,
I think the problem is : The production server requires authentication before you can send a mail using a specific email Id.
In ASP .Net there is no direct way to achieve this, so the solution Lau has suggested can be implemented in ASP .Net by adding a reference to the COM object.
"JD" wrote:
Lau Lei
Thanks for the quick reply, my bad for not pointing this out but this was using asp.net and not visual basic.
See code down below
'Put user code to initialize the page here Dim oMail As System.Web.Mail .SmtpMail Dim oMailMsg As New System.Web.Mail .MailMessage Dim sServer As String Dim sMsgBody As New System.Text.Str ingBuilder Dim sAutoMsgBody As New System.Text.Str ingBuilder
Try
'Check to see if there is any postback, if there is none then send the message If Not IsPostBack Then With oMail 'Set the mail server name .SmtpServer = ConfigurationSe ttings.AppSetti ngs("SmtpServer ")
'Get the name of the server that this resides on sServer = Request.ServerV ariables("SERVE R_NAME") With oMailMsg
'Set the body format .BodyFormat = Mail.MailFormat .Html 'Set the body content With sMsgBody .Append("Form Name:" & Request.Form("F ormName") & "<br>") .Append("<br>") .Append("First Name: " & Request.Form("F irstName") & "<br>") End With
.Body = sMsgBody.ToStri ng() & vbCrLf & "Server: " & sServer
''Automate response email 'With sAutoMsgBody ' .Append("<p>bla h blah</p>") ' .Append("<br>") 'End With
'With oMailMsg ' 'Take it from the email address that was entered on the contact form ' .To = Request.Form("e mail") ' 'Set the body format ' .BodyFormat = Mail.MailFormat .Html ' 'Subject line ' .Subject = "Automated response" ' 'From address ' .From = ConfigurationSe ttings.AppSetti ngs("CustFromSi te") ' 'Body ' .Body = sAutoMsgBody.To String() 'End With ''Send the email '.Send(oMailMsg )
End With 'Clean up oMail = Nothing oMailMsg = Nothing sMsgBody = Nothing 'Check to see if this is going to a custom thank you page or not If Len(Request.For m("RedirectPath ")) > 0 Then 'Redirect the site to the custom thank you page Response.Redire ct(Request.Form ("RedirectPath" )) End If
End If Catch ex As Exception 'To be done yet Response.Write( ex.Message) Response.Write( ex.StackTrace)
End Try
-- Sent via .NET Newsgroups http://www.dotnetnewsgroups.com
This works for me (and no COM wrapper stuff or CDO objects needed):
System.Web.Mail .MailMessage mail = new System.Web.Mail .MailMessage();
mail.To = destinationAddr esses;
mail.From = fromAddress;
mail.Subject = subjectLine;
mail.Body = mailBody;
mail.Fields.Add ("http://schemas.microso ft.com/cdo/configuration/smtpauthenticat e",
"1"); //basic authentication
mail.Fields.Add ("http://schemas.microso ft.com/cdo/configuration/sendusername",
m_SMTPLoginID); //set your username here
mail.Fields.Add ("http://schemas.microso ft.com/cdo/configuration/sendpassword",
m_SMTPLoginPW); //set your password here
System.Web.Mail .SmtpMail.SmtpS erver = m_SMTPMailServe r; // e.g.,
"mail.MyDomain. com"; //your smtp server goes here
System.Web.Mail .SmtpMail.Send( mail );
-HTH
"JD" <jd****@dalys.u s> wrote in message
news:Oa******** ******@TK2MSFTN GP14.phx.gbl... It would seem that you may be right
.Fields("http://schemas.microso ft.com/cdo/configuration/sendusing") = 2
.Fields("http://schemas.microso ft.com/cdo/configuration/smtpserver").va lues = "mail.nemo. com"
.Fields("http://schemas.microso ft.com/cdo/configuration/smtpserverport" ).values = 25
.Fields.Add("ht tp://schemas.microso ft.com/cdo/configuration/smtpauthenticat e", "1") 'basic authentication
.Fields.Add("ht tp://schemas.microso ft.com/cdo/configuration/sendusername", "crush") 'set your username here
.Fields.Add("ht tp://schemas.microso ft.com/cdo/configuration/sendpassword", "totallydud e") 'set your password here
it fails on the first line above and I get the error message down below Object variable or With block variable not set. at Microsoft.Visua lBasic.Compiler Services.LateBi nding.InternalL ateSet(Object o, Type& objType, String name, Object[] args, String[] paramnames, Boolean OptimisticSet, CallType UseCallType) at Microsoft.Visua lBasic.Compiler Services.LateBi nding.LateSetCo mplex(Object o, Type objType, String name, Object[] args, String[] paramnames, Boolean OptimisticSet, Boolean RValueBase) at blueconnect.sen dmail.Page_PreR ender(Object sender, EventArgs e) in C:\projects\Doc root\OtherClien ts\jci\app_incl udes\sendmail.a spx.vb:line 49 "Mayur Shah" <Mayur Sh**@discussion s.microsoft.com> wrote in message news:6C******** *************** ***********@mic rosoft.com... JD,
I think the problem is : The production server requires authentication before you can send a mail using a specific email Id.
In ASP .Net there is no direct way to achieve this, so the solution Lau has suggested can be implemented in ASP .Net by adding a reference to the COM object.
"JD" wrote:
Lau Lei
Thanks for the quick reply, my bad for not pointing this out but this was using asp.net and not visual basic.
See code down below
'Put user code to initialize the page here Dim oMail As System.Web.Mail .SmtpMail Dim oMailMsg As New System.Web.Mail .MailMessage Dim sServer As String Dim sMsgBody As New System.Text.Str ingBuilder Dim sAutoMsgBody As New System.Text.Str ingBuilder
Try
'Check to see if there is any postback, if there is none then send the message If Not IsPostBack Then With oMail 'Set the mail server name .SmtpServer = ConfigurationSe ttings.AppSetti ngs("SmtpServer ")
'Get the name of the server that this resides on sServer = Request.ServerV ariables("SERVE R_NAME") With oMailMsg
'Set the body format .BodyFormat = Mail.MailFormat .Html 'Set the body content With sMsgBody .Append("Form Name:" & Request.Form("F ormName") & "<br>") .Append("<br>") .Append("First Name: " & Request.Form("F irstName") & "<br>") End With
.Body = sMsgBody.ToStri ng() & vbCrLf & "Server: " & sServer
''Automate response email 'With sAutoMsgBody ' .Append("<p>bla h blah</p>") ' .Append("<br>") 'End With
'With oMailMsg ' 'Take it from the email address that was entered on the contact form ' .To = Request.Form("e mail") ' 'Set the body format ' .BodyFormat = Mail.MailFormat .Html ' 'Subject line ' .Subject = "Automated response" ' 'From address ' .From = ConfigurationSe ttings.AppSetti ngs("CustFromSi te") ' 'Body ' .Body = sAutoMsgBody.To String() 'End With ''Send the email '.Send(oMailMsg )
End With 'Clean up oMail = Nothing oMailMsg = Nothing sMsgBody = Nothing 'Check to see if this is going to a custom thank you page or not If Len(Request.For m("RedirectPath ")) > 0 Then 'Redirect the site to the custom thank you page Response.Redire ct(Request.Form ("RedirectPath" )) End If
End If Catch ex As Exception 'To be done yet Response.Write( ex.Message) Response.Write( ex.StackTrace)
End Try
-- Sent via .NET Newsgroups http://www.dotnetnewsgroups.com
Thanks everyone, I was able to get it work after I tried out Jeremy S.
suggestion, learn something new tonight or morning or whatever time it is
now. Issue closed.
"JD" <jd****@dalys.u s> wrote in message
news:uC******** ******@TK2MSFTN GP15.phx.gbl... Is it possible using the smtp class in asp.net to send emails and authenticate to the mail server that is sending the emails out.
Currently I have a web application that works fine on my machine, will send email to both my company email addresses and to non-company email addresses. However, as soon as I move the app into the production server it does not send email to non company email addresses. What I mean by company is our domain could @domain.com and it will work fine sending emails to any one with that email address, but anyone without that in their email address and it crashes. Any help on this would be appreciated.
-- J. D
Keep in mind that the method I showed to you is officially "undocument ed" -
meaning it might not be supported in the future. I suspect that's why this
solution is rarely recommended.
I'm sure the MVPs around here are aware of this undocumented solution - but
they don't recommend it - and probably for good reason. I'd be interested in
knowing why. This question is posed with some regularity and they always
seem to recommend some more complicated method that relies on CDO/COM
wrapper-based solution.
-JS
"JD" <jd****@dalys.u s> wrote in message
news:OL******** ******@TK2MSFTN GP14.phx.gbl... Thanks everyone, I was able to get it work after I tried out Jeremy S. suggestion, learn something new tonight or morning or whatever time it is now. Issue closed.
"JD" <jd****@dalys.u s> wrote in message news:uC******** ******@TK2MSFTN GP15.phx.gbl... Is it possible using the smtp class in asp.net to send emails and authenticate to the mail server that is sending the emails out.
Currently I have a web application that works fine on my machine, will send email to both my company email addresses and to non-company email addresses. However, as soon as I move the app into the production server it does not send email to non company email addresses. What I mean by company is our domain could @domain.com and it will work fine sending emails to any one with that email address, but anyone without that in their email address and it crashes. Any help on this would be appreciated.
-- J. D
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Dan Boyle |
last post by:
Hi,
I am having difficulty connection to an smtp host. I am using the
following code but I don't think I fully understand what smtp host can
be used.
function setSMTPParams($host = null, $port = null, $helo = null, $auth
= null, $user = null, $pass = null)
{
if (!is_null($host)) $this->smtp_params = $host;
|
by: Nancy |
last post by:
Hi, Guys,
Is there any other way to use python or mod_python writing a web page?
I mean, not use "form.py/email", no SMTP server.
<form action="form.py/email" method="POST"> ...
Thanks a lot.
Nancy W
|
by: Almir |
last post by:
I hate this Net::SMTP stuff, everything works fine but for the suject
field. I see no way of having it show in an email when sent. Has
anyone had this problem, can anyone explain why there are no
documentations on smtp or better ones at least. I just need the
subject field to show.
$smtp = Net::SMTP->new('some.your.com');
$smtp->mail ($mailfrom);
#the administrator's email goes here
$smtp->to('mine@your.com');
|
by: RandRace |
last post by:
I'm having some problems with a little script i wrote using net::smtp.
I originally wrote it in linux where it works perfectly. I tried to
use it from windows the other day and it doesn't work. It connects to
the server and prints the banner but will not send mail.
Here is my script:
use Net::SMTP;
my $smtp = Net::SMTP->new('smtp.comcast.net') or die "Can't Open
server"!";
|
by: Shannon Clyde |
last post by:
SMTP + relay + auth in an IPSEC tunnel to connect to our primary SMTP mail
server (GroupWise) from the Web server looks like it would work fine, but is
it the best way?
I am aware of CDOSYS and some commercial DLLs that allow devs to send mail
from within .ASP and .NET without local SMTP service running.
Is there any OTHER way to connect to an external SMTP server for mail
delivery from a .NET application?
| |
by: dale zhang |
last post by:
Hi,
I write an asp.net web application. It has a “Contact Us” page, where users
fill in their email, subject and text and hit send. Then the email will go to
my hard coded yahoo email account.
I was using optimum online service with smtp server as “mail.optonline.net”.
I can receive email correctly.
Now I switch to verizon DSL. I change my smtp server accordingly as
|
by: bivin |
last post by:
hai
i am requesting your technical support.
please help me.
i have been working with this for five days.
the problem is relating with the smtp.
i am trying to send an email from the asp.net page.
earlier it was showing send using not find error.
|
by: antonyliu2002 |
last post by:
I've set up the virtual smtp server on my IIS 5.1 like so:
1. Assign IP address to "All Unassigned", and listen to port 25.
2. Access Connection granted to "127.0.0.1".
3. Relay only allow "127.0.0.1".
4. Authentication: "Anonymous access" only.
5. Outbound connection listen to TCP 25.
Besides,
|
by: jcor |
last post by:
Hi, I'm trying some code to send a mail with my script. This is it:
#!/usr/bin/perl
use Net::SMTP;
my $smtp_server='62.193.245.15';
my $smtp = Net::SMTP->new($smtp_server) or die "Can't Open server\n";
$smtp->mail('joao.correia@tvn.pt');
$smtp->to('jcor@sapo.pt');
$smtp->auth("joao.correia@tvn.pt","*password*");
|
by: jimhill10 |
last post by:
I have a perl script that creates an email attachment file from POST data on a web page. This works just fine. I want to customize the email body to contain all of the text data from the file itself. I thought this would be just a matter of using the $smtp->datasend($POSTvalues) with the $values coming from the names on the web page posting the data. Can someone show me what the correct code snippet would be? Here is my code:
...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
| |
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |