[E2007][cdoex]the subject and attach file name (has both japanese and korean characters) not show correctly RRS feed

  • Question

  • I am trying to backup/restore an email in the store. the email shows normal before I backup and restore. but the subject and attach file name cannot display correctly after I restore.

    exchange 2007 version: 08.01.0240.006

    win2008 server EE


    use the cdoex to backup and restore a message

    the code is like this:

    	CComPtr< IMessage > cdoexMessage;
    	CComPtr< IDataSource > cdoexDataSource;
     CComBSTR uid(account._uid.c_str()), pwd(account._pwd.c_str());
    	if (!SUCCEEDED(cdoexMessage.CoCreateInstance(__uuidof(Message))))
    		return false;
    		return false;
    									conn, 				adModeRead,									adFailIfNotExists,									adOpenSource,									uid,										pwd))
    	return false;
    CComPtr< _Stream > cdoStream;
    	if (!SUCCEEDED(cdoexBodyPart->GetStream(&cdoStream)))
    		return false;
    	ADO_LONGPTR length = 0;
    	CComVariant partBin;
     cdoStream->Read(length, &partBin);


    the mail is created through owa. I input the subject as "لا_폴", the content is same "لا_폴", added an attach file named "لا_폴";

    after backup and restore, the content is correct (still shows "لا_폴"), but the subject and attach file name display ???.

    the issue seems to be when backup the subject is not saved correctly.


    X-MS-Has-Attach: yes
    Content-Class: urn:content-classes:message
    MIME-Version: 1.0
    Content-Transfer-Encoding: 7bit
    Content-Type: multipart/mixed;
    Subject: =?utf-8?B?7Y+0642U?=
    Date: Wed, 27 Jul 2011 10:19:05 +0800




    Content-Type: text/plain;
    Content-Transfer-Encoding: base64



    My question is why the conent shows normal but the subject and attach file name altered?

    I appreciate your help.


    Wednesday, July 27, 2011 5:39 AM