Home / Software / Computer programming / MAPI SEND MAIL QUERY
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] - (Bottom) Print
Author Topic: MAPI SEND MAIL QUERY  (Read 754 times)
tika
Guest
« on: April 16, 2007, 04:32:41 AM »

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 :)




IP logged
Sidewinder
Guru



Thanked: 97
Posts: 4,341

Experience: Familiar
OS: Windows 7

« Reply #1 on: April 18, 2007, 06:12:35 PM »

The example cited here should help.

Good luck. 8)
IP logged

If you don't know where you are going, any road will get you there

                                                                            -Lewis Carroll
tika
Guest
« Reply #2 on: April 20, 2007, 02:42:16 AM »

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???
IP logged
Pages: [1] - (Top) Print 
Home / Software / Computer programming / MAPI SEND MAIL QUERY « previous next »
 


Login with username, password and session length

Old Forum Search | Forum Rules
Copyright © 2010 Computer Hope ® All rights reserved.
Powered by SMF 2.0 RC3 | SMF © 2006–2010, Simple Machines LLC
Page created in 0.092 seconds with 20 queries.