WABOpenEx callback function

[WABOpenEx is no longer available for use as of Windows Vista.]

Provides access to the Windows Address Book (WAB) through a number of object interfaces. The root interface is IAddrBook, which is a subset of the MAPI implementation of IAddrBook.

Syntax

WABOpenEx Wabopenex;

HRESULT Wabopenex(
  LPADRBOOK *lppAdrBook,
  LPWABOBJECT *lppWABObject,
  LPWAB_PARAM lpWP,
  DWORD Reserved,
  ALLOCATEBUFFER *fnAllocateBuffer,
  ALLOCATEMORE *fnAllocateMore,
  FREEBUFFER *fnFreeBuffer
)
{...}

Parameters

lppAdrBook

Type: LPADRBOOK*

Address of a pointer to the IAddrBook interface returned by the function.

lppWABObject

Type: LPWABOBJECT*

Address of a pointer to the IWABObject interface returned by the function.

lpWP

Reserved

fnAllocateBuffer

fnAllocateMore

fnFreeBuffer

Return Value

Type: HRESULT

If this callback function succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

This function calls the WABOpen function, and the extra parameters lpfnAllocateBuffer, lpfnAllocateMore, and lpfnFreeBuffer are ignored.

WABOpenEx is an extended version of WABOpen that enables developers to specify the memory allocation functions used by WAB to return buffers to the client. If you pass one allocation routine, you must pass all three routines: MAPIAllocateBuffer, MAPIAllocateMore, and MAPIFreeBuffer.

If you do not need the extra memory allocation functionality of WABOpenEx, use WABOpen instead.

Note  When you specify memory allocation routines with WABOpenEx, these routines globally replace the WAB internal routines for this process. Other threads may still call WABOpen, but the memory will be allocated with those routines previously passed to WABOpenEx.
 

Requirements

   
Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header wabapi.h