Share via


FormFactory

The FormFactory function must be implemented to return a reference to the IFormProvider interface, which allows Messaging to create the plug-in's custom read and compose forms. The FORMFACTORYFUNC type defines a pointer to this function.

Note   The FormFactory function is available only on Windows Mobile 2002. For Windows Mobile 2003 and later, use the FormFactoryEx function.

Syntax

HRESULT FormFactory (
  LPCWSTR pszMsgClass,
  IFormProvider ** ppObj,
);

Parameters

  • pszMsgClass
    [in] Reference to the message's message class property.
  • ppObj
    [out] Reference to the plug-in's IFormProvider interface. Returns NULL if pszMsgClass is valid but the object cannot be created.

Return Values

This function returns an appropriate HRESULT value, such as the following:

  • S_OK
    The function successfully returned a reference to the IFormProvider interface.
  • MAPI_E_INVALID_PARAMETER
    The input parameter is NULL.
  • MAPI_E_NOT_ENOUGH_MEMORY
    A memory allocation failed.

Requirements

Pocket PC: Windows Mobile 2002
OS Versions: Windows CE 3.0
Header: cemapi.h
Library: cemapi.lib

See Also

MAPI Functions

Messaging

Send feedback on this topic to the authors.

© 2005 Microsoft Corporation. All rights reserved.