Azerthur
asked on
Send an email
I'm giving 50 pts for a fully working code doing the following things :
-send a mail to
adress : string with an object
subject : string from the adress ( optionnal )
origin : string saying
Memo1.lines.text
I need it to do it automatically without the user having to give any confirmation, it can use directly an smtp or just use the default maiiling program
-send a mail to
adress : string with an object
subject : string from the adress ( optionnal )
origin : string saying
Memo1.lines.text
I need it to do it automatically without the user having to give any confirmation, it can use directly an smtp or just use the default maiiling program
d4jaj1 ,
>>PS, if you want code examples, you may need to add some more points.
thats not how e.e works.
if you propose your comment as the answer then if you can you should at least provide a quick demo,
what would it take ..2 minutes ..mm.
>>PS, if you want code examples, you may need to add some more points.
thats not how e.e works.
if you propose your comment as the answer then if you can you should at least provide a quick demo,
what would it take ..2 minutes ..mm.
if you want a nice demo of using mapi see here:
http://www.bhnet.com.br/~simonet/archive/mapimail.zip
http://www.bhnet.com.br/~simonet/archive/mapimail.zip
inthe,
that is howe this how this works, and i've been here a lot longer than you. The 'customer' has a right to accept or reject any answer they choose - try not to think for them. Also, my answer is my proposed answer - definitely don't attempt to thionk for me!
that is howe this how this works, and i've been here a lot longer than you. The 'customer' has a right to accept or reject any answer they choose - try not to think for them. Also, my answer is my proposed answer - definitely don't attempt to thionk for me!
ASKER
Adjusted points from 50 to 60
ASKER
Delphi 3 standard, sorry no smtp component, maybe if you send the component....
ASKER
The file offerered by inthe seems nice but unfortunately it doesn't work, I get a
A mapi compliant messaging application cannot be found in the system
A mapi compliant messaging application cannot be found in the system
thionk
d4jaj1 :
>> i've been here a lot longer than you
that's a point, but :
d4jaj1 : 19941 points
vs
inthe : 298744 points
is a much better point for me.
What you state as an answer could only rejected.
The only answers that should be directly submitted as answers should come with the code.
We should answer a question only if we are sure it will be accepted as is...
The other times we should only comment questions. If the 'customer' likes your comment he will invite you to answer the question.
To compare the 'customer' satisfaction of you two :
Last 10 Grade(s) Received by d4jaj1 :
B C B C C C C C C A
and
Last 10 Grade(s) Received by inthe:
A A A A A A A A B B
sounds like your technic, d4jaj1, is not
the best.
And no, I don't know Inthe personnaly, and yes I know that he does not need me to argue against you.
It's just that I do not agree with your ee vision...
Regards.
John.
>> i've been here a lot longer than you
that's a point, but :
d4jaj1 : 19941 points
vs
inthe : 298744 points
is a much better point for me.
What you state as an answer could only rejected.
The only answers that should be directly submitted as answers should come with the code.
We should answer a question only if we are sure it will be accepted as is...
The other times we should only comment questions. If the 'customer' likes your comment he will invite you to answer the question.
To compare the 'customer' satisfaction of you two :
Last 10 Grade(s) Received by d4jaj1 :
B C B C C C C C C A
and
Last 10 Grade(s) Received by inthe:
A A A A A A A A B B
sounds like your technic, d4jaj1, is not
the best.
And no, I don't know Inthe personnaly, and yes I know that he does not need me to argue against you.
It's just that I do not agree with your ee vision...
Regards.
John.
I agree. InThe has always given full and comprehensive answers, where required. Also, I think it is rude to say "Well you give me more points and I'll do this for you." I think that's a little playground-like really.
Nicely said John. You the man.
Nicely said John. You the man.
Another point - what is the point of ever posting an answer?????
Comments can be accepted as answers, so why even have the option of submitting an answer?
Comments can be accepted as answers, so why even have the option of submitting an answer?
Experts, please, lets get back on topic and cut the customer some slack, this is only his/her second question :)
Azerthur I think inthe actually gave you the tool for this in his answer to your question about FTP.
darinw
Customer Service
Azerthur I think inthe actually gave you the tool for this in his answer to your question about FTP.
darinw
Customer Service
ASKER
I know, I went again to ICS but it still doesn't work !!!!!
;-(
Seems like I need a Tsmtpcli that is not included
;-(
Seems like I need a Tsmtpcli that is not included
Azerthur,
Try these components. Thier documentations claims it will work with D3 Pro and greater. So it might not work with Standard, but it is worth a try.
http://sak.org.ar/html/sakemail.html
Try these components. Thier documentations claims it will work with D3 Pro and greater. So it might not work with Standard, but it is worth a try.
http://sak.org.ar/html/sakemail.html
There is a TEmail freware component that I use for doing something like that
You just drop this component in a form and with a functions like these you can send the email getting MAPI service.
TDModEmail Form :
------------------
..
..
..
type
Email1: TEmail;
..
..
..
procedure TDModEmail.DModEmailCreate (Sender: TObject);
begin
MailLogon;
end;
function TDModEMail.MailLogon: boolean;
begin
if (Email1.Logon <> EMAIL_OK) then
begin
Result := False;
ErrorMsg('MAPI can't connected.');
end
else
Result := True;
end;
function TDModEMail.SendMail(ListRe cept,ListC C,ListMsg, ListAttach :TStrings;
sSubject :String): Boolean;
var
I,Size : integer;
P: Pchar;
sMsg :string;
begin
If (ListRecept.Count = 0) and (ListCC.Count = 0) Then
Begin
Result := False;
Exit;
End;
If Not MailLogon Then
Begin
Result := False;
Exit;
End;
sMsg := '';
For I:= 0 To ListMsg.Count-1 do
Begin
sMsg := sMsg + ListMsg.Strings[I] + Chr(13);
End;
Email1.Recipient := ListRecept;
Email1.CC := ListCC;
Email1.Attachment := ListAttach;
Email1.SetLongText(PChar(s Msg));
Email1.Subject := sSubject;
if (Email1.SendMail <> EMAIL_OK) then
ErrorMsg('MAPI its not available')
else
Result := True;
end;
Check for this component.. there is in some web recources. If you want, I can send it to you.
Hope This Helps!
You just drop this component in a form and with a functions like these you can send the email getting MAPI service.
TDModEmail Form :
------------------
..
..
..
type
Email1: TEmail;
..
..
..
procedure TDModEmail.DModEmailCreate
begin
MailLogon;
end;
function TDModEMail.MailLogon: boolean;
begin
if (Email1.Logon <> EMAIL_OK) then
begin
Result := False;
ErrorMsg('MAPI can't connected.');
end
else
Result := True;
end;
function TDModEMail.SendMail(ListRe
sSubject :String): Boolean;
var
I,Size : integer;
P: Pchar;
sMsg :string;
begin
If (ListRecept.Count = 0) and (ListCC.Count = 0) Then
Begin
Result := False;
Exit;
End;
If Not MailLogon Then
Begin
Result := False;
Exit;
End;
sMsg := '';
For I:= 0 To ListMsg.Count-1 do
Begin
sMsg := sMsg + ListMsg.Strings[I] + Chr(13);
End;
Email1.Recipient := ListRecept;
Email1.CC := ListCC;
Email1.Attachment := ListAttach;
Email1.SetLongText(PChar(s
Email1.Subject := sSubject;
if (Email1.SendMail <> EMAIL_OK) then
ErrorMsg('MAPI its not available')
else
Result := True;
end;
Check for this component.. there is in some web recources. If you want, I can send it to you.
Hope This Helps!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
NNsmtp.body := memo1.lines;
will work just fine. There's also a demo of this compoent in teh Delphi demos directory. Let me know if you need additional help.
Jay
PS, if you want code examples, you may need to add some more points.