Click here to Skip to main content
15,890,438 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: didn't expect from u anyway! Pin
Christian Graus22-Sep-05 12:22
protectorChristian Graus22-Sep-05 12:22 
GeneralRe: the memory leak Pin
Jörgen Sigvardsson21-Sep-05 11:14
Jörgen Sigvardsson21-Sep-05 11:14 
Generalabsolutely! Pin
valerie9921-Sep-05 11:53
valerie9921-Sep-05 11:53 
QuestionRe: absolutely! Pin
Maximilien21-Sep-05 13:42
Maximilien21-Sep-05 13:42 
AnswerRe: absolutely! Pin
valerie9922-Sep-05 3:59
valerie9922-Sep-05 3:59 
Questiontrying to read rtfbody of email Pin
pnpfriend21-Sep-05 9:51
pnpfriend21-Sep-05 9:51 
AnswerRe: trying to read rtfbody of email Pin
David Crow21-Sep-05 10:09
David Crow21-Sep-05 10:09 
GeneralRe: trying to read rtfbody of email Pin
pnpfriend22-Sep-05 4:19
pnpfriend22-Sep-05 4:19 
Oh I'm sorry.
I'm getting error at readrtf () function.
I think I'm passing the wrong information to readrtf().. especially parameter one. Mapirtf.cpp explain about readrtf() defination as follow: but I dont' know where to get Profile name..
<br />
////////////////////////////////////////////////////////////////////////////////////////////<br />
// Function: readrtf<br />
//<br />
// Input:    <br />
//		LPSTR lpProfileName   Profile to logon to<br />
//		LPSTR lpMsgID         String representation of Hex Entry ID of message to open<br />
//      LPSTR lpStoreID       String representation of Hex Entry ID of message store<br />
// Output:   <br />
//		LPSTR *lpRTF          Pointer to LPSTR where RTF text will be stored<br />
// Return:   <br />
//		bool            indicates whether the process of reading the rtf text from the<br />
//                      message was sucessful<br />
// Calls:<br />
//		LoggedOn<br />
//		StoreOpened<br />
//		MessageOpened<br />
//<br />
// Purpose:  Read the RTF text from the body of the specified message in the specified message store<br />
////////////////////////////////////////////////////////////////////////////////////////////<br />
DllExport HRESULT WINAPI readrtf (LPSTR lpProfileName,<br />
								   LPSTR lpMsgIDSrc,<br />
								   LPSTR lpStoreIDSrc,<br />
								   LPSTR *lpRTF)<br />



In the example of readrtf() provided by microsoft, http://support.microsoft.com/?kbid=172038[^] get the session, mapi message and the logon then readrtf(). I'd tried to get the session of as follow, but doesnt' work.. I dont' know how to covert that vb example code (from 172038) to c++.

<br />
<br />
	CoInitialize(NULL);<br />
_ApplicationPtr pApp;	<br />
		hr=pApp.CreateInstance(__uuidof(Application));<br />
		if (FAILED(hr))<br />
		{<br />
			MessageBox("Unable to instantiate Outlook.","Outlook Error",MB_OK);<br />
			return;<br />
		}<br />
		<br />
		pNS = pApp->GetNamespace(_bstr_t("MAPI"));<br />
		_NameSpacePtr session = pApp->GetNamespace(_bstr_t("MAPI.Session"));<br />
<br />
<br />


thanks for your reply David.
GeneralRe: trying to read rtfbody of email Pin
pnpfriend22-Sep-05 5:40
pnpfriend22-Sep-05 5:40 
QuestionWhere to place code to be ran immediately after all mfc contruction is completed. Pin
Dan Neely21-Sep-05 9:38
Dan Neely21-Sep-05 9:38 
AnswerRe: Where to place code to be ran immediately after all mfc contruction is completed. Pin
David Crow21-Sep-05 10:08
David Crow21-Sep-05 10:08 
GeneralRe: Where to place code to be ran immediately after all mfc contruction is completed. Pin
Dan Neely21-Sep-05 10:28
Dan Neely21-Sep-05 10:28 
GeneralRe: Where to place code to be ran immediately after all mfc contruction is completed. Pin
Blake Miller22-Sep-05 4:18
Blake Miller22-Sep-05 4:18 
QuestionNewlines in my Edit Box Pin
bugDanny21-Sep-05 9:29
bugDanny21-Sep-05 9:29 
AnswerRe: Newlines in my Edit Box Pin
David Crow21-Sep-05 9:34
David Crow21-Sep-05 9:34 
AnswerRe: Newlines in my Edit Box Pin
Chris Losinger21-Sep-05 9:36
professionalChris Losinger21-Sep-05 9:36 
GeneralRe: Newlines in my Edit Box Pin
bugDanny21-Sep-05 10:58
bugDanny21-Sep-05 10:58 
GeneralRe: Newlines in my Edit Box Pin
Chris Losinger21-Sep-05 11:53
professionalChris Losinger21-Sep-05 11:53 
QuestionAdding menu items to a mfc sdi app Pin
Dan Neely21-Sep-05 9:07
Dan Neely21-Sep-05 9:07 
AnswerRe: Adding menu items to a mfc sdi app Pin
Dan Neely21-Sep-05 9:25
Dan Neely21-Sep-05 9:25 
QuestionClosing windows Pin
Demian Panello21-Sep-05 8:35
Demian Panello21-Sep-05 8:35 
GeneralRe: Closing windows Pin
ddmcr21-Sep-05 8:58
ddmcr21-Sep-05 8:58 
AnswerRe: Closing windows Pin
David Crow21-Sep-05 9:31
David Crow21-Sep-05 9:31 
AnswerRe: Closing windows Pin
ThatsAlok21-Sep-05 19:03
ThatsAlok21-Sep-05 19:03 
Questionwebbrowser &amp; internet explorer Pin
RaymondM21-Sep-05 7:27
RaymondM21-Sep-05 7:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.