V
VB Programmer
I am trying to send a simple email through my ASP.NET website. This is how
I do it.
Try
System.Web.Mail.SmtpMail.Send("(e-mail address removed)",
"(e-mail address removed)", "test", "TESTING 123")
Catch ex As Exception
Response.Write(ex.ToString)
End Try
Exit Sub
I get this error:
"System.Web.HttpException: Could not access 'CDO.Message' object. --->
System.Reflection.TargetInvocationException: Exception has been thrown by
the target of an invocation. --->
System.Runtime.InteropServices.COMException (0x80040220): The "SendUsing"
configuration value is invalid.
--- End of inner exception stack trace ---
at System.RuntimeType.InvokeDispMethod(String name, BindingFlags
invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32
culture, String[] namedParameters)
at System.RuntimeType.InvokeMember(String name, BindingFlags invokeAttr,
Binder binder, Object target, Object[] args, ParameterModifier[] modifiers,
CultureInfo culture, String[] namedParameters)
at System.Type.InvokeMember(String name, BindingFlags invokeAttr, Binder
binder, Object target, Object[] args)
at System.Web.Mail.LateBoundAccessHelper.CallMethod(Type type, Object
obj, String methodName, Object[] args)
at System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String
methodName, Object[] args)
--- End of inner exception stack trace ---
at System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String
methodName, Object[] args)
at System.Web.Mail.CdoSysHelper.Send(MailMessage message)
at System.Web.Mail.CdoSysHelper.Send(String from, String to, String
subject, String messageText)
at System.Web.Mail.SmtpMail.Send(String from, String to, String subject,
String messageText)
at POWERWeb.TestCode.Page_Load(Object sender, EventArgs e) in
C:\Inetpub\wwwroot\POWERWeb\TestCode.aspx.vb:line 36"
Any ideas? Thanks.
I do it.
Try
System.Web.Mail.SmtpMail.Send("(e-mail address removed)",
"(e-mail address removed)", "test", "TESTING 123")
Catch ex As Exception
Response.Write(ex.ToString)
End Try
Exit Sub
I get this error:
"System.Web.HttpException: Could not access 'CDO.Message' object. --->
System.Reflection.TargetInvocationException: Exception has been thrown by
the target of an invocation. --->
System.Runtime.InteropServices.COMException (0x80040220): The "SendUsing"
configuration value is invalid.
--- End of inner exception stack trace ---
at System.RuntimeType.InvokeDispMethod(String name, BindingFlags
invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32
culture, String[] namedParameters)
at System.RuntimeType.InvokeMember(String name, BindingFlags invokeAttr,
Binder binder, Object target, Object[] args, ParameterModifier[] modifiers,
CultureInfo culture, String[] namedParameters)
at System.Type.InvokeMember(String name, BindingFlags invokeAttr, Binder
binder, Object target, Object[] args)
at System.Web.Mail.LateBoundAccessHelper.CallMethod(Type type, Object
obj, String methodName, Object[] args)
at System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String
methodName, Object[] args)
--- End of inner exception stack trace ---
at System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String
methodName, Object[] args)
at System.Web.Mail.CdoSysHelper.Send(MailMessage message)
at System.Web.Mail.CdoSysHelper.Send(String from, String to, String
subject, String messageText)
at System.Web.Mail.SmtpMail.Send(String from, String to, String subject,
String messageText)
at POWERWeb.TestCode.Page_Load(Object sender, EventArgs e) in
C:\Inetpub\wwwroot\POWERWeb\TestCode.aspx.vb:line 36"
Any ideas? Thanks.