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 = "<server name>";
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:yourname@domain.co.in
I fetch
SMTP:yourname@domain.co.in 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<char,struct std::char_traits<char>,class std::allocator<char> >
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
