Could not create 'CDONTS.NewMail' object

  • Thread starter Thread starter kiran
  • Start date Start date
K

kiran

Hi,
I wrote mailing service code for my Windows Application. When I was trying
to send a mail thru my application, an Error occurs only for Windows NT
saying that "Could not create 'CDONTS.NewMail' object". It works fine with
Windows 2000 and Windows XP. Could some one pls help to get rid of the
error?

Thanks in advance,
Kiran
 
Hi Kiran,

True it started with NT/5x it is also not on W9x
I wrote mailing service code for my Windows Application. When I was trying
to send a mail thru my application, an Error occurs only for Windows NT
saying that "Could not create 'CDONTS.NewMail' object". It works fine with
Windows 2000 and Windows XP. Could some one pls help to get rid of the
error?

Cor
 
Hi Kiran,

For a real Cdonc (kind of sending batch mail) no?

I did not see it in this newsgroups also, the only simple thing I have for
you is this but that is not sending batch mail. (I did not try it on an NT4x
or a W9x, but I think it will go)
(I have also one from the webbrowser if this would not go, but I should not
know why this one would not go however I am not absolute sure as I said.)

\\\by Fergus Cooney & small corrections by Cor
'A reference to System.Web may be necessary
'in the Project for this Import to work.
Imports System.Web.HttpUtility

Public Sub StartDefaultMail (sTo As String, _
Optional sSubject As String = "", _
Optional sMessage As String = "")
Try
sTo = UrlEncode (sTo)
sSubject = sSubject
sMessage = sMessage
Process.Start ("mailto:" & sTo & "?subject=" _
& sSubject & "&body=" & sMessage)

Catch e As Exception
MsgBox ("Couldn't start default email application" _
& vbCrLf & e.Message)
'or
Throw New Exception ("Couldn't start default email app", e)
End Try
End Sub
///

I hope this helps a little bit?

Cor
 
hi kiran,

i am facing almost the same problem. i made the file in windows 2000 and was working properly (perfectly). now when i try the same code in xp professional it says "Could not create".
Could u please send ur files which works on xp(ASAP). will be great help.

Regads


**********************************************************************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP & ASP.NET resources...
 
Back
Top