ASP.NET - "Could not access 'CDO.Message' object."

 
Vista:

"Could not access 'CDO.Message' object."

Publicado por Marta (29 intervenciones) el 22/12/2004 10:37:59
Hola a todos.
Estoy intentando mandar un email con el siguiente codigo:
private void sendMail(string From, string To, string Subject, string Mensaje, string SmtpServer, string Attach)
{
MailMessage oMsg = new MailMessage();
oMsg.From = From;
oMsg.To = To;
oMsg.Subject = Subject;

oMsg.BodyFormat = MailFormat.Html;
oMsg.Body = Mensaje;
if (Attach !=null)
{
MailAttachment myAttachment = new MailAttachment(Attach);
oMsg.Attachments.Add(myAttachment);
}
SmtpMail.SmtpServer = SmtpServer;
SmtpMail.Send(oMsg);
}

El problem surge cuando en el To paso dos direcciones: "[email protected];[email protected]" me devuelve el siguiente error :"Could not access 'CDO.Message' object."
si solo paso una direccion el e-mail se manda correctamente.
Gracias a todos
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder