BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Replacing From.Text in IdMessage

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Internet Winsock
View previous topic :: View next topic  
Author Message
Jeff Swanberg
Guest





PostPosted: Fri Jan 14, 2005 7:03 pm    Post subject: Replacing From.Text in IdMessage Reply with quote



When I send out an email using my SMTP server, the domain name for that
server is being appended to the "From.Text" for my IdMessage component. Is
there a way to block that from happening??

My code is:

with IdMsgSend do
begin
Body.Assign(Memo2.Lines);
From.Text := Edit1.Text;
ReplyTo.EMailAddresses := Edit2.Text;
Recipients.EMailAddresses := Edit3.Text;
end;

The email sends just fine but the "From" box on the recipient's end will
read:
Test ; @swanbergcomputing.com
even though all that is put into the Edit1.Text property is:
Test User


js


Back to top
Remy Lebeau (TeamB)
Guest





PostPosted: Fri Jan 14, 2005 9:08 pm    Post subject: Re: Replacing From.Text in IdMessage Reply with quote




"Jeff Swanberg" <jswanberg (AT) swanbergcomputing (DOT) com> wrote


Quote:
When I send out an email using my SMTP server, the domain name for that
server is being appended to the "From.Text" for my IdMessage component.

As well it should, because you are not using the TIdMessage properly to
begin with.

Quote:
From.Text := Edit1.Text;
snip
all that is put into the Edit1.Text property is:
Test User

That is not valid. You must provide an actual email address.


Gambit



Back to top
Marcelo
Guest





PostPosted: Sat Jan 15, 2005 2:45 pm    Post subject: Re: Replacing From.Text in IdMessage Reply with quote



did you tried the "replyto" property ?

you not block the "from" email..
but if you want to use a smtp to send and other email that isnīt in the smtp
domain...
some smtp blocks send email from other email that isnīt in their domain...
using
the replyto , you can send email and receive in other domain...

regards
Marcelo


"Remy Lebeau (TeamB)" <no.spam (AT) no (DOT) spam.com> escreveu na mensagem
news:41e8344f (AT) newsgroups (DOT) borland.com...

"Jeff Swanberg" <jswanberg (AT) swanbergcomputing (DOT) com> wrote


Quote:
When I send out an email using my SMTP server, the domain name for that
server is being appended to the "From.Text" for my IdMessage component.

As well it should, because you are not using the TIdMessage properly to
begin with.

Quote:
From.Text := Edit1.Text;
snip
all that is put into the Edit1.Text property is:
Test User

That is not valid. You must provide an actual email address.


Gambit




Back to top
Remy Lebeau (TeamB)
Guest





PostPosted: Sat Jan 15, 2005 11:15 pm    Post subject: Re: Replacing From.Text in IdMessage Reply with quote


"Marcelo" <mcgal-N-O-S-P-A-M-ig.com.br> wrote


Quote:
did you tried the "replyto" property ?

That won't have any effect. The issue Jeff is seeing is caused by the From
property, because that is the value that the SMTP server is actually told to
send the message from. The ReplyTo address is nothing more than extra data
that is part of the raw message data that gets copied as-is to the
recipients. The SMTP server has to be told who the message is from and who
it is going to BEFORE the actual message data is sent to the server.

Quote:
you not block the "from" email..
but if you want to use a smtp to send and other email that isnīt
in the smtp domain...
some smtp blocks send email from other email that isnīt in
their domain... using the replyto , you can send email and
receive in other domain...

You still have to provide a valid From address regardless of whether you
specify a ReplyTo address. The From address tells the SMTP server which
account within its domain is the account to use for sending the message to
the recipients.


Gambit



Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Internet Winsock All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.