Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_cdo thread: CDONTS: how to connect to web server from local machine in order to send email using asp code?


Message #1 by kapinjal@m... on Mon, 30 Apr 2001 05:16:18
hi guys..

i just recently started my job as a asp developer..but i gota question..if 

the web server is on the server and the comp i have is a client and if i 

wanna use the CDONTS to send email then i need to connect my local machine 

to that web server by some kinda code...i guess...



can someone help me out with that please?

kaps
Message #2 by "Michiel van Otegem" <michiel_lists@a...> on Mon, 30 Apr 2001 10:53:17 +0200
Here's the deal:

- You install a webserver

- You install the SMTP service with the webserver (comes with IIS)

- You write an ASP page (on the server) that sends mail using CDONTS

- You open a browser on the client and request that ASP page (maybe fill in

some fields...)



---

Michiel van Otegem

ASP/XML Teacher

off-list email:  michiel@a...



ASPNL.com / IT Composer

www:    http://www.aspnl.com

---

----- Original Message -----

From: <kapinjal@m...>

To: "ASP CDO" <asp_cdo@p...>

Sent: Monday, April 30, 2001 5:16 AM

Subject: [asp_cdo] CDONTS: how to connect to web server from local machine

in order to send email using asp code?





> hi guys..

> i just recently started my job as a asp developer..but i gota question..if

> the web server is on the server and the comp i have is a client and if i

> wanna use the CDONTS to send email then i need to connect my local machine

> to that web server by some kinda code...i guess...

>

> can someone help me out with that please?

> kaps

>

Message #3 by "kaps pandya" <kapinjal@m...> on Tue, 1 May 2001 00:04:03 +1000
well but on the client side the IIS is not installed, and i am a 

client using the network and i dont have web server on my computer so 

what i need to write in the asp code so that my code will connect to 

the SMTP server and send that email?



regards

kaps



Message #4 by "Earls, Michael (CORP)" <Michael.Earls@C...> on Mon, 30 Apr 2001 12:00:44 -0400
Start with complete, well formed sentences using capitalization like you

learned in school.  It's difficult to understand what you are asking with

all of that mess.



I'm guessing this is what you need...



SendMail.asp



Dim objMailer

Set objMailer = Server.CreteObject("CDONTS.NewMail")



'----------------------------------

' Email importance constants

'----------------------------------

Const IMPORTANCE_HIGH = 2

Const IMPORTANCE_MEDIUM = 1

Const IMPORTANCE_LOW = 0

'----------------------------------



email_importance = IMPORTANCE_HIGH



objMailer.to = "Someone(kapinjal@m...)"

objMailer.from = "Michael Earls(someone@h...)"

objMailer.subject ="This is a test"

objMailer.Importance = email_importance

objMailer.body = "This is the body of the test message.  Good grammar and

puncuation will go a long way to getting professional assistance from your

peers."

objMailer.send



Set objMailer = Nothing





'------------



I apologize in advance for the harsh approach to your message, but these

mail lists are filled with volunteers who don't have a great deal of time to

decipher poor grammar and secret encoded words like "u", "ur", "comp".  Just

use the full word in a complete sentence.  It's much easier to read that

way.



Good luck, welcome to ASP programming.  I'm sure you'll have many years of

satisfaction from your career choice.



Michael Earls



-----Original Message-----

From: kapinjal@m... [mailto:kapinjal@m...]

Sent: Sunday, April 29, 2001 10:16 PM

To: ASP CDO

Subject: [asp_cdo] CDONTS: how to connect to web server from local

machine in order to send email using asp code?





hi guys..

i just recently started my job as a asp developer..but i gota question..if 

the web server is on the server and the comp i have is a client and if i 

wanna use the CDONTS to send email then i need to connect my local machine 

to that web server by some kinda code...i guess...



can someone help me out with that please?

kaps




  Return to Index