IQueryParserManager::CreateLoadedParser Method

Creates a new instance of a IQueryParser interface implementation. This instance of the query parser is loaded with the schema for the specified catalog and is localized to a specified language. All other settings are initialized to default settings.

Syntax

HRESULT CreateLoadedParser(      
    LPCWSTR pszCatalog,
    LANGID langidForKeywords,
    REFIID riid,
    void **ppQueryParser
);

Parameters

  • pszCatalog
    [in] The name of the catalog to use. Permitted values are SystemIndex and an empty string (for a trivial schema with no properties).
  • langidForKeywords
    [in] The LANGID used to select the localized language for keywords.
  • riid
    [in] The IID of the IQueryParser interface implementation.
  • ppQueryParser
    [out, retval]  Receives a pointer to the newly created parser. The calling application must release it by calling its IUnknown::Release method.

Return Value

Returns S_OK if successful, or an error value otherwise.

Remarks

If %LOCALAPPDATA% is not available, then this method fails. You should call IQueryParserManager::SetOption to point to a different folder like %ProgramData%.