Collecting Data to Search the Address Book

When a client or user agent wants to search the address book for a particular Address Book object, the client MUST retrieve the search template for the address book and display the template to the user to collect the data to use to search the address book. To retrieve the search template that is used to collect information to use to search the address book, the NspiGetTemplateInfo function, as specified in [MS-NSPI] and [MS-OXNSPI] section, MUST be called with the ulType parameter set to the DT_SEARCH (as defined in [MS-NSPI] and [MS-OXNSPI] section and the pDN parameter set to 0x00000000. The dwFlags parameter contains a bitwise combination that MUST include the bit for the TI_TEMPLATE (0x00000001) flag set so the template will be retrieved and MAY contain the bits for the TI_HELPFILE_NAME (0x00000020) and TI_HELPFILE (0x00000040) flags for a value of 0x00000061. <6> The function's dwCodePage input parameter is the code page in which the strings in the template are stored and the ppData return parameter contains a pointer to a PropertyRow_r structure, as specified in [MS-NSPI] and [MS-OXNSPI] section 2.2.3, that contains the data needed to create and display the dialog. When the dialog is completed and dismissed, the data from the dialog can be used to create a Restriction_r structure, as defined in [MS-NSPI] and [MS-OXNSPI] section, from the controls that have been filled in. This Restriction_r structure can be passed to NspiGetMatches function in the Filter input parameter to locate an Address Book object, as specified in [MS-NSPI] and [MS-OXNSPI] section