Make your own free website on Tripod.com

CreateToolbarEx


Creates a toolbar window and adds the specified buttons to the toolbar.

HWND CreateToolbarEx(
    HWND hwnd,
    DWORD ws,
    UINT wID, 
    int nBitmaps, 
    HINSTANCE hBMInst, 
    UINT wBMID, 
    LPCTBBUTTON lpButtons, 
    int iNumButtons, 
    int dxButton, 
    int dyButton, 
    int dxBitmap, 
    int dyBitmap, 
    UINT uStructSize
);

Parameters

hwnd
Handle to the parent window for the toolbar.
ws
Window styles for the toolbar. This parameter must specify at least the WS_CHILD style. It can also include a combination of styles as discussed in Toolbar Control and Button Styles.
wID
Control identifier for the toolbar.
nBitmaps
Number of button images contained in the bitmap specified by hBMInst and wBMID.
hBMInst
Module instance with the executable file that contains the bitmap resource.
wBMID
Resource identifier for the bitmap resource. If hBMInst is NULL, this parameter must be a valid bitmap handle.
lpButtons
Address of an array of TBBUTTON structures that contain information about the buttons to add to the toolbar.
iNumButtons
Number of buttons to add to the toolbar.
dxButton
Width, in pixels, of the buttons to add to the toolbar.
dyButton
Height, in pixels, of the buttons to add to the toolbar.
dxBitmap
Width, in pixels, of the button images to add to the buttons in the toolbar.
dyBitmap
Height, in pixels, of the button images to add to the buttons in the toolbar.
uStructSize
Size of a TBBUTTON structure.

Return Values

Returns the window handle to the toolbar if successful, or NULL otherwise. To get extended error information, call GetLastError.

Remarks

Windows 95: The system can support a maximum of 16,364 window handles.

Requirements

  Windows NT/2000: Requires Windows NT 3.51 or later
  Windows 95/98: Requires Windows 95 or later
  Header: Declared in commctrl.h.
  Import Library: comctl32.lib.

© 2000 Microsoft Corporation. All rights reserved. Terms of use.