CToolbar.SetMaxTextRowsmethod
Sets the maximum number of text rows displayed on a toolbar button.
Syntax
FUNCTION SetMaxTextRows (BYVAL hToolbar AS HWND, BYVAL iMaxRows AS LONG) AS BOOLEAN
Parameters
| Name | Description | |
|---|---|---|
hToolbar | Handle to the toolbar control. | |
iMaxRows | Maximum number of rows of text that can be displayed. |
Return value
If this function succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
Description
Sets the maximum number of text rows displayed on a toolbar button.
Remarks
To cause text to wrap, you must set the maximum button width by sending a TB_SETBUTTONWIDTH message. The text wraps at a word break; line breaks ("\n") in the text are ignored. Text in TBSTYLE_LIST toolbars is always shown on a single line.
Reference
- Include file
CToolbar.inc - Defined in AfxNova/CToolbar.inc:1202
- Documented in Windows/WIndows Controls/CToolbar Class.md
- Topic: CToolbar Class