Help Center

CTooltip.AddToolmethod

Registers a tool with a Tooltip control.

WindowsmethodCTooltip.incdocumented

Syntax

FUNCTION AddTool (BYVAL hTooltip AS HWND, BYVAL lpti AS TOOLINFOW PTR) AS BOOLEAN

Parameters

NameDescription
hTooltipThe handle of the Tooltip control.
lptiPointer to a TOOLINFOW structure containing information that the tooltip control needs to display text for the tool. The cbSize member of this structure must be filled in before sending this message.

Return value

Returns TRUE if successful, or FALSE otherwise.

Description

Registers a tool with a Tooltip control.

Remarks

Although the name of the message implicitly indicates the "addition of a tool", it must be made clear that this message merely records a set of specific settings for what is called "a tool", however a ToolTip can be displayed even when there is no "tool" itself (a visual control with a handle). For this reason, this message should be interpreted as "add a set of specific settings for the display of a ToolTip ". A ToolTip window can be displayed in several different ways and each of these ways can be registered via the TTM_ADDTOOL message.

Reference

  • Include file CTooltip.inc
  • Defined in AfxNova/CTooltip.inc:167
  • Documented in Windows/WIndows Controls/CTooltip Class.md
  • Topic: CTooltip Class