none
The lpszA of PR_DISPLAY_NAME is alias name instead of display name RRS feed

  • Question

  • Hello everyone,

    When I open recipient table of a mail by GetRecipientTable, I noticed the lpszA of PR_DISPLAY_NAME is always alias name instead of display name if the display name includes no ANSI charactor.

    Who had experienced it and give me some help? Thanks in advance.

    Thursday, August 22, 2013 6:58 AM

All replies

  • So the question is how was the recipient added and resolved?

    What do you see in MFCMAPI or OutlookSpy? 


    Dmitry Streblechenko (MVP)
    http://www.dimastr.com/redemption
    Redemption - what the Outlook
    Object Model should have been
    Version 5.5 is now available!

    Thursday, August 22, 2013 2:41 PM
  • Thanks for your feedback.

    The mail is just sent by outlook. And, on outlook and MFCMAPI, the recipients list can show proper display name. The below picture is the MFCMAPI show.

    Meanwhile, I noticed if the sender is on Exchange 2010, the issue does not exist. if on exchange 2007, the issue comes up.

    Friday, August 23, 2013 3:34 AM
  • Looks perfectly fine to me. Are you sure you are not reading PR_7BIT_DISPLAY_NAME instead of PR_DISPLAY_NAME?

    Dmitry Streblechenko (MVP)
    http://www.dimastr.com/redemption
    Redemption - what the Outlook
    Object Model should have been
    Version 5.5 is now available!

    Friday, August 23, 2013 4:23 AM
  • Yes. I'm reading PR_DISPLAY_NAME. Here is the snippet:

    LPSPropValue pPR_DISPLAY_NAME = PpropFindProp(rows->aRow[i].lpProps,rows->aRow[i].cValues,PR_DISPLAY_NAME);

    if (pPR_DISPLAY_NAME)
                {
                    aRecipient.name(_trimSurroundQuotes(pPR_DISPLAY_NAME->Value.lpszA).c_str());

    ..............

    Friday, August 23, 2013 5:39 AM
  • What is your implementation of PpropFindProp? Why do you need it if you explicitly set table columns and hence know the property index?

    Dmitry Streblechenko (MVP)
    http://www.dimastr.com/redemption
    Redemption - what the Outlook
    Object Model should have been
    Version 5.5 is now available!

    Sunday, August 25, 2013 4:23 PM
  • PpropFindProp is just from MS VC SDK, not implemented by myself. I used the interface to try to find the property and then read its value.

    The interface has something wrong?

    Monday, August 26, 2013 3:22 AM