Hi,
I'm using CDO object to send email but it doesn't send any email and it does
not give an error.
My code look like this:
Dim iMsg2
Dim iConf2
Dim Flds2
Const cdoSendUsingPor t = 2
set iMsg2 = CreateObject("C DO.Message")
set iConf2 = CreateObject("C DO.Configuratio n")
Set Flds2 = iConf.Fields
' Set the CDOSYS configuration fields to use port 25 on the SMTP server.
With Flds2
.Item("http://schemas.microso ft.com/cdo/configuration/sendusing") =
cdoSendUsingPor t
'ToDo: Enter name or IP address of remote SMTP server.
.Item("http://schemas.microso ft.com/cdo/configuration/smtpserver") =
"My_SMTP_Server "
..Item("http://schemas.microso ft.com/cdo/configuration/smtpconnectiont imeout"
) = 10
.Update
End With
' Apply the settings to the message.
With iMsg2
Set .Configuration = iConf
.To = "<to@bla.co m>" 'ToDo: Enter a valid email address.
.From = "fr**@bla.c om" 'ToDo: Enter a valid email address.
.Subject = "This is a test CDOSYS message (Sent via Port 25)"
.HTMLBody = "Test"
.Send
End With
' Clean up variables.
Set iMsg2 = Nothing
Set iConf2 = Nothing
Set Flds2 = Nothing
I have checked that a new file called "NTFS_f3a93f240 1c34ab30000013f .EML" is
created in the folder "C:\Inetpub\mai lroot\Queue\"
Also if I try to use CDO 1.x version I get an error.The code look like this:
Dim objNewMail
Set objNewMail = Server.CreateOb ject("CDONTS.Ne wMail")
objNewMail.From = "my****@myserve r.com"
objNewMail.To = "my****@myserve r.com"
objNewMail.Subj ect = "Test Subject"
objNewMail.Body = "Test Body"
objNewMail.Send
Set objNewMail = Nothing
Response.Write "Email has been sent"
I think the problem arises from SMTP Server.How can I understand that my
SMTP Server works fine?
Thanks,
Salim 3 9532
Have you looked in the event log to see if your server is unable to resolved
the recipient's domain?
Is the SMTP service running, or have you restarted it?
Ray at work
"Salim Afþar" <sa****@luckyey e.com> wrote in message
news:uY******** ******@TK2MSFTN GP11.phx.gbl... I have checked that a new file called "NTFS_f3a93f240 1c34ab30000013f .EML"
is created in the folder "C:\Inetpub\mai lroot\Queue\"
How can I understand SMTP service is running?
I looked at the Internet Information Services and the Default SMTP Virtual
Server is running.
And also I looked at Event Viewer and saw this error:
Message delivery to the remote domain 'opet.com.tr' failed for the following
reason: An internal DNS error caused a failure to find the remote server.
Thanks a lot,
Salim
"Ray at <%=sLocation% >" <as*@me.forit > wrote in message
news:ug******** ******@TK2MSFTN GP11.phx.gbl... Have you looked in the event log to see if your server is unable to
resolved the recipient's domain?
Is the SMTP service running, or have you restarted it?
Ray at work
"Salim Afþar" <sa****@luckyey e.com> wrote in message news:uY******** ******@TK2MSFTN GP11.phx.gbl...
I have checked that a new file called
"NTFS_f3a93f240 1c34ab30000013f .EML" is created in the folder "C:\Inetpub\mai lroot\Queue\"
You should talk to your DNS admin then. Try sending an e-mail to another
domain, like yo************* **@hotmail.com or something and see if that
sends.
Ray at work
"Salim Afþar" <sa****@luckyey e.com> wrote in message
news:uD******** *****@tk2msftng p13.phx.gbl... How can I understand SMTP service is running? I looked at the Internet Information Services and the Default SMTP Virtual Server is running. And also I looked at Event Viewer and saw this error: Message delivery to the remote domain 'opet.com.tr' failed for the
following reason: An internal DNS error caused a failure to find the remote server. Thanks a lot, Salim
"Ray at <%=sLocation% >" <as*@me.forit > wrote in message news:ug******** ******@TK2MSFTN GP11.phx.gbl... Have you looked in the event log to see if your server is unable to resolved the recipient's domain?
Is the SMTP service running, or have you restarted it?
Ray at work
"Salim Afþar" <sa****@luckyey e.com> wrote in message news:uY******** ******@TK2MSFTN GP11.phx.gbl...
I have checked that a new file called
"NTFS_f3a93f240 1c34ab30000013f .EML" is created in the folder "C:\Inetpub\mai lroot\Queue\"
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: NotGiven |
last post by:
|
by: mahsa |
last post by:
Hi I try to send email using this code it seems the code doesn't hhave any
problem but it doesn't send any emailv do you have any idea?
MailMessage objEmail = new MailMessage();
objEmail.To = "mahsa_em@yahoo.com";
objEmail.From = "INFO@FLOORONE.COM";
objEmail.Cc = "mahsa_em@hotmail.com";
objEmail.Subject = "Test Email";
objEmail.Body = "test" ;
objEmail.Priority = MailPriority.High;
|
by: Abhishek Srivastava |
last post by:
Hello All,
I wrote the follownig program
using System;
using System.Web.Mail;
public class MailHelper
{
public static void SendMail(string mailId, string author, string email,
|
by: Michal |
last post by:
Hi
I need to connect to Exchange 5.5 from .Net Web Application and send email
using user profile.
I did it two years ago on ASP but now I have to migrate it to .Net.
I can not find any solutions in msdn to resolve it.
Any idea how I can do this ?
Michal
|
by: Ron |
last post by:
hi guys,
I am trying to send email using smtpMail.
I can send emails inside the organization, but out of the organization I get
an error "The server rejected one or more recipient addresses. The server
response was: 550 5.7.1 Unable to relay for ........"
now I tried to add username and password for the server to relay but it is
still not working.
this is the example i used:
| |
by: Andreas |
last post by:
I am working with three computers, my developing computer, a Web Server and a
Mail Server (Exchange).
I am trying to send a email from the Web Server via the Mail Server to a
valid email address with this code:
MailMessage msgMail = new MailMessage();
msgMail.To = "test@address.com";
msgMail.From = "from@address.com";
msgMail.Subject = "Mail Example Subject";
|
by: CLEAR-RCIC |
last post by:
I want to send an email from our Intranet site to myself whenever an error
happens. Our manager will not let us install SMTP on the web server. Is it
possible to send email programatically without SMTP installed?
|
by: Muhammad Deeraf |
last post by:
I am using following code to send an email to a gmail account.
MailMessage mm = new MailMessage("myaccount@gmail.com","targetaccount@gmail.com","Subject: be careful","hi target, you are going to miss the train");
NetworkCredential nc = new NetworkCredential("myaccount@gmail.com","myaccountpassword","http://www.gmail.com");
SmtpClient sc = new SmtpClient("smtp.gmail.com",587);
sc.Credential = nc;
sc.Send(mm);
The above code doesn't...
|
by: Warren Tang |
last post by:
Hi
I am using the mail function to send a mail like this:
$b = mail("my_real_email_address@gmail.com", "Hello from PHP",
"Hi, finally sent an email successfully");
But it failed. Could you guide me to get it work?
Regards
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
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: 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...
| |