none
Does Message Store contains a property of PROP_TAG(PT_BINARY, PROP_ID_NULL)? RRS feed

  • Question

  • Hi,

    In the document for HrValidateIPMSubtree at https://docs.microsoft.com/en-us/office/client-developer/outlook/mapi/hrvalidateipmsubtree , it said if the full IPM tree is created, then in the returned property array, there will be a property of tag PROP_TAG(PT_BINARY, PROP_ID_NULL).

    Therefore, after I use HrValidateIPMSubtree to create the full IPM tree with parameter MAPI_FULL_IPM_TREE, I invoke:

    pMsgStore->GetProps

    to get the value for the tag PROP_TAG(PT_BINARY, PROP_ID_NULL). But the return result is E_INVALIDARG. Why? Where there is really such a property with tag PROP_TAG(PT_BINARY, PROP_ID_NULL) exists in the message store?

    Wednesday, June 26, 2019 8:29 AM

All replies

  • Hello,

    Why don't you pass a pointer to an array of SPropValue structures to return a special property tag?

    lppProps

    [in, out] Pointer to a pointer to an array of SPropValue structures that contains property values for the PR_VALID_FOLDER_MASK (PidTagValidFolderMask) property and for the appropriate folder entry identifier properties. If HrValidateIPMSubtree creates an Inbox in the message store, the SPropValue array includes an Inbox entry identifier with a special property tag coded as  PROP_TAG(PT_BINARY, PROP_ID_NULL).

    MFCMAPI uses the HrValidateIPMSubtree method to add standard folders to a message store. So, I'd recommend playing with MFCMAPI to understand how the HrValidateIPMSubtree function works.


    profile for Eugene Astafiev at Stack Overflow, Q&A for professional and enthusiast programmers

    Wednesday, June 26, 2019 9:42 AM
  • Hello,

    Why don't you pass a pointer to an array of SPropValue structures to return a special property tag?

    profile for Eugene Astafiev at Stack Overflow, Q&A for professional and enthusiast programmers

    Hi, Eugene,

    An array of SPropValue are only available after invoking HrValidateIPMSubtree. However, if I get a PST file from the client, I need to open the message store and check its Inbox folder, in such a case, I have to use lpMsgStore->GetProps to obtain the properties.

    Wednesday, June 26, 2019 12:53 PM
  • > An array of SPropValue are only available after invoking HrValidateIPMSubtree.

    So, you can't run the HrValidateIPMSubtree method against the message store before calling lpMsgStore->GetProps, right?


    profile for Eugene Astafiev at Stack Overflow, Q&A for professional and enthusiast programmers

    Wednesday, June 26, 2019 1:13 PM