Condividi tramite


DTBLBUTTON

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

Contains information about a button control for a dialog box built from a display table.

Header file:

Mapidefs.h

Related macro:

SizedDtblButton

typedef struct _DTBLBUTTON
{
  ULONG ulbLpszLabel;
  ULONG ulFlags;
  ULONG ulPRControl;
} DTBLBUTTON, FAR *LPDTBLBUTTON;

Members

  • ulbLpszLabel
    Position in memory of the character string that is displayed on the button.

  • ulFlags
    Bitmask of flags used to designate the format of the label pointed to by the ulbLpszLabel member. The following flag can be set:

    • MAPI_UNICODE
      The label is in Unicode format. If the MAPI_UNICODE flag is not set, the label is in ANSI format.
  • ulPRControl
    Property tag for a property of type PT_OBJECT that implements the IMAPIControl interface. When the button is clicked, MAPI calls the IMAPIProp::OpenProperty method for the display table's IMAPIProp implementation to retrieve this property.

Remarks

A DTBLBUTTON structure describes a button a control that, when clicked, allows a user to begin an operation. Typically, clicking a button causes a modal dialog box to be displayed or a programmatic task to be invoked. Service providers can implement anything through a button control. If the button is supposed to perform a task based on the values of other controls, those controls must have set the DT_SET_IMMEDIATE flag.

The ulbLpszLabel member is the position in memory of the character string that is displayed on the button. Service providers can add an ampersand character (&) to indicate a Windows accelerator in the button label. Pressing an accelerator key has the same effect as clicking the button.

The ulPRControl member describes an object property that, when opened with the IMAPIProp::OpenProperty method, returns a pointer to a control object. Implementing a control object that supports the IMAPIControl interface is a way to extend the MAPI feature set and define the operation or task that occurs when the button is clicked. IMAPIControl supplies two methods for manipulating buttons: GetState to disable or enable buttons and Activate to handle button clicks.

For an overview of display tables, see Display Tables. For information about how to implement a display table, see Implementing a Display Table.

See Also

Reference

DTCTL

Concepts

MAPI Structures