473,387 Members | 1,497 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

SMTP - need help understanding

Hi,

I'm successfully sending email using the following code snip but what I
don't understand is the use of "Http://schema" references. What
happens to all email programs that use these references if this site
were to ever go down? Is there a way to hard code the content behind
these addresses? The program I am writing will live as a Windows
Service on a server. Can I be 100% that this server will have access
to this schema address? Just seems weird to me.

Thanks if anybody can better explain.
With objMailMessage

..Fields.Add("http://schemas.microsoft.com/cdo/configuration/smtpserver",
strSMTPAddress)

..Fields.Add("http://schemas.microsoft.com/cdo/configuration/smtpserverport",
25)

..Fields.Add("http://schemas.microsoft.com/cdo/configuration/sendusing",
cdoSendUsingPort)

..Fields.Add("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate",
cdoBasic)

..Fields.Add("http://schemas.microsoft.com/cdo/configuration/sendusername",
strSendUserName)

..Fields.Add("http://schemas.microsoft.com/cdo/configuration/sendpassword",
strSendUserPassword)
.From = strFromAddress
.To = strToAddress
.Bcc = strBccAddress
.Cc = strCcAddress
.Subject = strSubject
.Body = strBody
End With

Mar 24 '06 #1
4 990

"ZRexRider" <je****@ptd.net> wrote in message
news:11**********************@e56g2000cwe.googlegr oups.com...
I'm successfully sending email using the following code snip but what I
don't understand is the use of "Http://schema" references. What
happens to all email programs that use these references if this site
were to ever go down? Is there a way to hard code the content behind
these addresses? The program I am writing will live as a Windows
Service on a server. Can I be 100% that this server will have access
to this schema address? Just seems weird to me.


Looks weird to me. This is J# but it works OK and should be almost the same
in VB

================================================
import System.Net.Mail.*;

private void btnSend_Click(Object sender, System.EventArgs e)
{
MailAddress myTo = new MailAddress(toaddress);
MailAddress myFrom = new MailAddress(fromaddress);
MailMessage myMessage = new MailMessage(myFrom, myTo);
myMessage.set_Body("This is the body");
myMessage.set_Subject("This is the subject");
SmtpClient myClient = new SmtpClient("smtp.server.net");
myClient.Send(myMessage);
}
================================================
toaddress and fromaddress should be email addresses in quotes
Mar 26 '06 #2
ZRexRider,

The http://schemas.microsoft.com references are namespaces (I think).
It doesn't actually go out to Microsoft's servers and get any
information. It is just a property.

They could have just as easily made the CDO object work the following
way (I'm not sure why they didn't, but there must be a good reason):
objMailMessage.sendUsing(smtpPort, 25)
objMailMessage.send

They must have developed the properties the way they did for
extensability or to conform to some standard.

But in the end, it doesn't use their servers. It is just a constant /
namespace.

Mar 26 '06 #3

Seth wrote:
ZRexRider,

The http://schemas.microsoft.com references are namespaces (I think).
It doesn't actually go out to Microsoft's servers and get any
information. It is just a property.

They could have just as easily made the CDO object work the following
way (I'm not sure why they didn't, but there must be a good reason):
objMailMessage.sendUsing(smtpPort, 25)
objMailMessage.send

They must have developed the properties the way they did for
extensability or to conform to some standard.

But in the end, it doesn't use their servers. It is just a constant /
namespace.


Thanks - that makes sense I guess. I wouldn't have needed these
settings at all except I was unable to find a property that would let
me set user ID and password since authentication is necessary with the
SMTP server Im using

Thanks again

Mar 26 '06 #4
There are a couple of options I can think of:

1. If using postfix, add the IP address to the mynetworks list and then
set it up to not require authentication for mynetworks.

2. it looks like you can set credentials using CDO. See
http://kb.seekdotnet.com/ViewArticle/152data.aspx.

Hope that helps.

Seth

Mar 26 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
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,...
2
by: David | last post by:
Hi Group, I'm having a few problems with getting an SMTP server configured on my Windows 2000 Server web server. My web server is co-located at my hosts and i use VNC to remotely access the web...
6
by: Jason | last post by:
Sorry for the post here but could not find an Exchange newgroup. I developed an application a year or 2 ago that sends SMTP email. The application allows the user to customize the text from...
5
by: Emmett Power | last post by:
Hi, I use Access to send emails through SMTP. I'd like to mirror the process and retrieve emails from my SMTP/Pop3 server without the intermediary of Outlook. I don't want to spend a lot of...
2
by: scorpion53061 | last post by:
I would like to know how you guys are handling this issue...... Some ISP's are now requiring authentication when using SMTP (such as orcsweb) while others are refusing to accept plain text...
34
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...
11
by: zaebos | last post by:
hi, i have this code which is part of a main program, to email from within the program a log file: int MailIt (char *mailserver, char *emailto, char *emailfrom, char *emailsubject, char...
9
by: Ted Boyd | last post by:
I have an ASP page that sends email using CDOSYS. If there is any type of failure that causes the email not to be sent, I don't have any way of knowing it. Is there any email component that will...
5
by: veralee | last post by:
I'm in dire need to use Net::SMTP. The server no longer uses "sendmail". I found an example of using Net::SMTP but I have to also include a user name and password for the server. The host provided...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
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,...
0
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...
0
Oralloy
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,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.