1.

Solve : MAPI SEND MAIL QUERY?

Answer»

Hi All ,

Can anyone help me reagrding MAPI send mail logic as soon as poosible.


I am supposed to get the SMTP server name from an ini file and have to send a mail through this server name.
 The syntax for getting the server name is :

mapird.lpszAddress = "";
QUOTES are required here

it should fetch the server name from an ini file.this is wat i gave in the ini file:

SMTP Server Name=SMTP:[email protected]

I fetch SMTP:[email protected] part from the ini file and store it in a variable named str using VC++.Now i call this variable str like given below:

mapird.lpszAddress =str;

This gives me a error like this:

error C2679: binary '=' : no operator defined which takes a right-hand operand of TYPE 'class std::basic_string,class std::allocator >


Please help me what to do.Im writing a code to send a mail from VC++.also let me know if i can find any other code where i DONT have to hardcode the server name.

Thanks a lot in advance,
Tika




The example cited here should help.

Good luck. thanks!!!

this s wat we too have done but now the prob is we should send mail THRUGH SMTP in C++. have any idea on this???

if so pls help???



Discussion

No Comment Found