|
 |
asp_cdo thread: SV: RE: When I'm doing a CDONTS mail, can I use a remot- e SM TP-server?
Message #1 by Robbin Gille <robbin.gille@n...> on Tue, 3 Jul 2001 08:26:15 +0200
|
|
Thanks! Now I can try to do the ASP-page I tried before.
Thanks a lot.
Robbin
-----Ursprungligt meddelande-----
Fr=E5n: Eli Schilling [mailto:eschilli@t...]
Skickat: den 2 juli 2001 17:17
Till: ASP CDO
=C4mne: [asp_cdo] RE: When I'm doing a CDONTS mail, can I use a remote
SM
TP-server?
CDONTS cannot submit messages to a remote mail server. It requires a
local SMTP server running. If you want to do remote mail submission you
have to resort to CDOSYS (aka CDO for Windows 2000).
Here's a little CDOSZS snippet just to get you started (note that you
need to either declare the constants or use a metatag as described on
MSDN to get the constants working):
Set objConfiguration =3D CreateObject("CDO.Configuration")
Set objFields =3D objConfiguration.Fields
With objFields
.Item(cdoSendUsingMethod) =3D cdoSendUsingPort
.Item(cdoSMTPServerPort) =3D 25
.Item(cdoSMTPServer) =3D "YourMailServer.YourDomain.Com"
.Update
End With
Set objMessage =3D CreateObject("CDO.Message")
With objMessage
Set .Configuration =3D objConfiguration
.From =3D "YourOriginator@Y..."
.To =3D "TheRecipient@T..."
.Subject =3D "YourSubject"
'.TextBody =3D "YourTextBody"
.Send
End With
//This is from Siegfried in an earlier thread. Hope it helps.
-Eli
|
|
 |