ShowBalloonTooltip(CtrlId, Config) Displays a balloon tooltip over a control.

Syntax

rv = Send_Message(Ctrl, "OLE.ShowBalloonTooltip", CtrlId, Config)

Parameters

ParameterDescription
CtrlIdThe unique identifier of a subclassed control
ConfigThe balloon tooltip configuration settings. (See Remarks)

Remarks

The ShowBalloonTooltip can be used to show a balloon tooltip over any subclassed control. The tooltip will always point to the center of the control. The CtrlId parameter is the named identifier you supplied when subclassing the control. The Config parameter is multivalued and has the following structure:

PosNameTypeDescription
<1>TextTextThe balloon tooltip text
<2>TitleTextAn optional title for the balloon tooltip
<3>IconInteger0 = No Icon, 1 = Info Icon, 2 = Warning Icon, 3 = Error Icon
<4>DelayIntegerTime in milliseconds to remain visible

The configuration settings are very straightforward, just pass the ones you wish to change. If Delay is set to 0, then the balloon tooltip stays visible until the user clicks on it. If Delay is greater than zero, then the balloon tooltip will disappear when the time, in milliseconds, ellapses or until the user the clicks on it--whichever comes first.

Multiline text is supported. Simply delimite your lines either CRLFs or with @TMs.

Updating Tooltips

To update the contents of an already visible balloon tooltip, just call this method again for the same control.

Example

// Show a balloon tooltip in an EDITLINE with an info icon and a 5 second time limit 
Config = "" 
Config<1> = "Multiple line test":@TM:"Line 1":@TM:"Line 2" 
Config<2> = "This is My Title" 
Config<3> = 1 
Config<4> = 5000 
rv = Send_Message(@Window:".OLE_SUBCLASS", "OLE.ShowBalloonTooltip", @Window:".EDITLINE", Config)

See Also

HideBalloonTooltip

  • No labels