Skip to content

Latest commit

 

History

History
84 lines (50 loc) · 2.18 KB

tb-getbuttoninfo.md

File metadata and controls

84 lines (50 loc) · 2.18 KB
title description ms.assetid keywords topic_type api_name api_location api_type ms.topic ms.date
TB_GETBUTTONINFO message (Commctrl.h)
Retrieves extended information for a button in a toolbar.
87430dd2-43d1-4e33-96ac-d33f89a654b6
TB_GETBUTTONINFO message Windows Controls
apiref
TB_GETBUTTONINFO
TB_GETBUTTONINFOA
TB_GETBUTTONINFOW
Commctrl.h
HeaderDef
reference
05/31/2018

TB_GETBUTTONINFO message

Retrieves extended information for a button in a toolbar.

Parameters

wParam

Command identifier of the button.

lParam

Pointer to a TBBUTTONINFO structure that receives the button information. The cbSize and dwMask members of this structure must be filled in prior to sending this message.

Return value

Returns the zero-based index of the button, or -1 if an error occurs.

Remarks

When you use TB_ADDBUTTONS or TB_INSERTBUTTON to place buttons on the toolbar, the button text is commonly specified by its string pool index. TB_GETBUTTONINFO will not retrieve this string. To use TB_GETBUTTONINFO to retrieve button text, you must first set the text string with TB_SETBUTTONINFO. Once you have set the button text with TB_SETBUTTONINFO, you can no longer use the string pool index.

Requirements

Requirement Value
Minimum supported client
Windows Vista [desktop apps only]
Minimum supported server
Windows Server 2003 [desktop apps only]
Header
Commctrl.h
Unicode and ANSI names
TB_GETBUTTONINFOW (Unicode) and TB_GETBUTTONINFOA (ANSI)

See also

Reference

TB_SETBUTTONINFO

TB_GETBUTTONTEXT