Platform SDK: MAPI |
To issue a query meaningful to a custom message type, an application needs to know the properties expected on that message. To get a list of properties used by a custom message class, a client application queries the MAPI form manager. The form manager gets this information from the appropriate form configuration file so that this information can be used by client applications without the overhead of activating the form server itself. To do this, the client application calls IMAPIFormMgr::ResolveMessageClass, like this:
IMAPIFormInfo *pfrminf = NULL; hr = pfrmmgr->ResolveMessageClass("IPM.Demo", 0L, NULL, &pfrminf);
Note that the third argument to ResolveMessageClass is the folder containing the associated contents table that the query will search for form servers. NULL indicates that the form manager should search all available form containers. If the query is to run against a particular folder it is better to include the appropriate IMAPIFolder pointer instead.