Share via


CommandBands_GetRestoreInformation (Windows CE 5.0)

Send Feedback

This function retrieves information necessary to restore a band's current state, and places it in a COMMANDBANDSRESTOREINFO structure.

BOOL WINAPI CommandBands_GetRestoreInformation(HWND hwndCmdBands,UINTuBand,LPCOMMANDBANDSRESTOREINFOpcbri);

Parameters

  • hwndCmdBands
    [in] Handle to the command bands control's window. This handle is returned when the command bands control is created by the CommandBands_Create function.
  • uBand
    [in] Unsigned integer that contains the zero-based index of the band containing the command bar. Use RB_IDTOINDEX to get the index of the band before passing the index to this function.
  • pcbri
    [out] Pointer to an array of COMMANDBANDSRESTOREINFO structures that will receive information about the band's current state.

Return Values

TRUE indicates success. FALSE indicates failure.

Remarks

Use CommandBands_GetRestoreInformation to save information about the bands in a command bands control before you close the application window. Save the information in the registry, so the bands can be restored to their current state the next time the application is opened. The next time the application is opened, use the values returned in the fStyle and cxRestored fields of the COMMANDBANDSRESTOREINFO structure for the fStyle and cx fields of the REBARBANDINFO structure you pass to the CommandBands_AddBands function. After you have added all the bands to the control, use the RB_MAXIMIZEBAND message to maximize any band whose fMaximized field in the COMMANDBANDSRESTOREINFO structure is set to TRUE.

Requirements

OS Versions: Windows CE 2.0 and later.
Header: Commctrl.h.
Link Library: Commctrl.lib.

See Also

CommandBands_AddBands | CommandBands_Create | RB_IDTOINDEX | RB_MAXIMIZEBAND | COMMANDBANDSRESTOREINFO | REBARBANDINFO

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.