FTP | CCD | Buscar | Trucos | Trabajo | Foros |
|
Registrarse | FAQ | Miembros | Calendario | Guía de estilo | Temas de Hoy |
|
Herramientas | Buscar en Tema | Desplegado |
#11
|
|||
|
|||
Enviar archivos adjuntos
que tal foro:
tengo un problema al tratar de enviar los archivos adjuntos, uso delphi 2009 y componentes indy 10.2 o los que vienen por default si envia el ccorreo y todo, pero los archivos que llegan adjuntos vienen con extensión .dat, y eso es una lata, no se si a alguien ya le paso y que pudiera darm eun pocco de luz al respecto. añado mi codigo para enviar los correos: with IdMessage do begin Body.Assign(dbMemo1.Lines); From.Text := UserEmail; ReplyTo.EMailAddresses := UserEmail; Recipients.EMailAddresses := edtemailcte.Text; { To: header } Subject := UserName; { Subject: header } //Priority := TIdMessagePriority(cboPriority.ItemIndex); { Message Priority } //CCList.EMailAddresses := edtCC.Text; {CC} //BccList.EMailAddresses := edtBCC.Text; {BBC} //if chkReturnReciept.Checked then // begin {We set the recipient to the From E-Mail address } // ReceiptRecipient.Text := From.Text; // end //else // begin {indicate that there is no receipt recipiant} ReceiptRecipient.Text := ''; // end; end; {authentication settings} // case SmtpAuthType of // 0: idSMTP.AuthType := atNone; // 1: idSMTP.AuthType := atDefault; {Simple Login} //end; idSMTP.Username := SmtpServerUser; idSMTP.Password := SmtpServerPassword; {General setup} idSMTP.Host := SmtpServerName; idSMTP.Port := SmtpServerPort; {now we send the message} idSMTP.Connect; try idSMTP.Send(IdMessage); finally idSMTP.Disconnect; MessageDlg('Correo enviado satisfactoriamente',mtInformation,[mbOk],0); end; |
|
|
|