User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the VB.NET section within the Software Development category of DaniWeb, a massive community of 397,798 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,392 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our VB.NET advertiser:
Views: 7564 | Replies: 0
Reply
Join Date: Apr 2004
Posts: 1
Reputation: confusedinsc has a little shameless behaviour in the past 
Rep Power: 0
Solved Threads: 0
confusedinsc confusedinsc is offline Offline
Newbie Poster

Using CDO messaging service

  #1  
Apr 14th, 2004
I am getting an error message

"The trasport failed to connect to the server."

I know why I am getting the error, our mail server is having technical problems and won't let anyone connect to send or retrieve emails periodically. My question is, how do I go about queing these suckers until I can successfully connect, or are they just lost? Below is the code to do this:

Set objConfig = CreateObject("CDO.Configuration")
Set Fields = objConfig.Fields

' Set config fields we care about
With Fields
.Item(cdoSendUsingMethod) = cdoSendUsingPort
.Item(cdoSMTPServer) = "SMTP Server"
.Item(cdoSMTPServerPort) = 25
.Item(cdoSMTPConnectionTimeout) = 10
.Item(cdoSMTPAuthenticate) = cdoBasic
.Item(cdoSendUserName) = "userid"
.Item(cdoSendPassword) = "password"
.Update
End With
Set objMessage = CreateObject("CDO.Message")
Set objMessage.Configuration = objConfig
With objMessage
.To = "User Account Sending To"
.From = "User Account Sending From"
.Subject = "Subject"
.TextBody = "mailbody"
.Send
End With

GoTo CloseEverything
ErrorHandler:
' Something
CloseEverything:
Set Fields = Nothing
Set objMessage = Nothing
Set objConfig = Nothing

Thanks for Any and All Help!!
AddThis Social Bookmark Button
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

DaniWeb VB.NET Marketplace
Thread Tools Display Modes

Similar Threads
Other Threads in the VB.NET Forum

All times are GMT -4. The time now is 5:53 am.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC