Example

'© Dennis McKinney 2002
'You may use this code freely in your own programs.
'This code may not be redistributed, published in whole or in part,
'posted to any group or bulletin board, nor placed on any web site
'without the authors permission.

NoMainWin

'TOOLINFO structure
Struct ti, _
cbSize As long, _
uFlags As long, _
hwnd As long, _
uId As long, _
left As long, _
top As long, _
right As long, _
bottom As long, _
hinst As long, _
lpszText As ptr

ti.cbSize.struct = Len(ti.struct)
ti.uFlags.struct = 17

WindowWidth = 300
WindowHeight = 200
UpperLeftX = Int((DisplayWidth - WindowWidth) / 2)
UpperLeftY = Int((DisplayHeight - WindowHeight) / 2)

button #1.btn, "Red", [x], UL, 5, 5, 40, 25
button #1.btn2, "Blue", [x], UL, 50, 5, 40, 25
button #1.btn3, "Green", [x], UL, 95, 5, 40, 25
open "Easy Tooltips" for window as #1
print #1, "trapclose [quit]"
hParent = hwnd(#1)

hTT = CreateTooltip(hParent)
call AddTooltip hwnd(#1.btn),"Red",hTT
call AddTooltip hwnd(#1.btn2),"Blue",hTT
call AddTooltip hwnd(#1.btn3),"Green",hTT

wait

[quit]
close #1
end

[x]
wait


Function CreateTooltip(hParent)
CallDLL #user32, "CreateWindowExA",0 As long,"tooltips_class32" As ptr,_
0 As long,0 As long,_CW_USEDEFAULT As long,_CW_USEDEFAULT As long,_
_CW_USEDEFAULT As long,_CW_USEDEFAULT As long,hParent As long,_
0 As long,0 As long,0 As long,CreateTooltip As Ulong
End Function

Sub AddTooltip hWnd, Text$, hTT
ti.uId.struct = hWnd
ti.lpszText.struct = Text$
CallDLL #user32, "SendMessageA",hTT As long,1028 As long, _
0 As long,ti as ptr,ret As long
End Sub