How can I reduce the initial ToolTip delay in VB6?

  • Follow


I've read up on TTM_SETDELAYTIME, but this appears to relate to a
newly created tooltip. How can I change the Windows default tooltip's
initial delay from 500ms to, say, 10ms? I want one particular tooltip
(on my virtual piano keys) to appear as instantaneously as possible. 

(I could, of course, create my own tooltip popup, but if it's possible
to affect the standard tooltip initial delay I might as well use that,
since it is fine in all other respects.)

MM
0
Reply MM 9/10/2010 10:15:22 AM

"MM" <kylix_is@yahoo.co.uk> wrote in message 
news:621k86l47j1n223k37cce9g64q287jqrgh@4ax.com...
> I've read up on TTM_SETDELAYTIME, but this appears to relate to a
> newly created tooltip. How can I change the Windows default tooltip's
> initial delay from 500ms to, say, 10ms? I want one particular tooltip
> (on my virtual piano keys) to appear as instantaneously as possible.
>
> (I could, of course, create my own tooltip popup, but if it's possible
> to affect the standard tooltip initial delay I might as well use that,
> since it is fine in all other respects.)

I think VB tooltip is not using the common control tooltip, otherwise every 
EXE made with VB would have a dependency on the common controls DLL. 
However, it's possible that Microsoft compiled the tooltip control 
statically into the VB runtime. Also, by using Spy++ with a form with two 
buttons, VB tooltip window handle remains the same for each tooltip. The 
window class is "VBBubble", so you might be able to use some of that 
information to get what you want.



0
Reply Nobody 9/10/2010 11:54:34 AM


On Fri, 10 Sep 2010 07:54:34 -0400, "Nobody" <nobody@nobody.com>
wrote:

>"MM" <kylix_is@yahoo.co.uk> wrote in message 
>news:621k86l47j1n223k37cce9g64q287jqrgh@4ax.com...
>> I've read up on TTM_SETDELAYTIME, but this appears to relate to a
>> newly created tooltip. How can I change the Windows default tooltip's
>> initial delay from 500ms to, say, 10ms? I want one particular tooltip
>> (on my virtual piano keys) to appear as instantaneously as possible.
>>
>> (I could, of course, create my own tooltip popup, but if it's possible
>> to affect the standard tooltip initial delay I might as well use that,
>> since it is fine in all other respects.)
>
>I think VB tooltip is not using the common control tooltip, otherwise every 
>EXE made with VB would have a dependency on the common controls DLL. 
>However, it's possible that Microsoft compiled the tooltip control 
>statically into the VB runtime. Also, by using Spy++ with a form with two 
>buttons, VB tooltip window handle remains the same for each tooltip. The 
>window class is "VBBubble", so you might be able to use some of that 
>information to get what you want.

Google produced several hits for VBBubble, but also this:
http://btmtz.mvps.org/tooltip/

I quickly modified the demo code to add a call to change the initial
delay and bingo! The delay is now 5ms. The tooltip pops up
instantaneously.  However, this is creating a new tool tip, not the
VBBubble one, so I'll research this a bit further in case I find
something more on VBBubble, else I'll just use Brad Martinez's
solution.

Many thanks for the pointers!

MM
0
Reply MM 9/10/2010 4:36:26 PM

"Nobody" <nobody@nobody.com> wrote in message 
news:i6d69s$qr2$1@speranza.aioe.org...
: I think VB tooltip is not using the common control tooltip, otherwise 
every
: EXE made with VB would have a dependency on the common controls DLL.

So?  That particular DLL is part of the Windows OS. 

0
Reply Kevin 9/10/2010 5:27:38 PM

On Fri, 10 Sep 2010 13:27:38 -0400, "Kevin Provance" <k@p.c> wrote:

>
>"Nobody" <nobody@nobody.com> wrote in message 
>news:i6d69s$qr2$1@speranza.aioe.org...
>: I think VB tooltip is not using the common control tooltip, otherwise 
>every
>: EXE made with VB would have a dependency on the common controls DLL.
>
>So?  That particular DLL is part of the Windows OS. 

While it is fairly straightforward to create one's own tooltip, which
I've since done using Brad Martinez's tooltip example, it would be a
lot easier simply to call a Windows API to reset the initial display
for the inbuilt VBBubble tooltip. That 500ms initial delay must exist
SOMEwhere in the OS, but where? It'll almost certainly be a Long.

MM
0
Reply MM 9/10/2010 7:48:47 PM

You can send a TTM_SETDELAYTIME to set the delay.

SendMessage Handle, TTM_SETDELAYTIME, TTDT_AUTOPOP, 300

>That 500ms initial delay must exist
> SOMEwhere in the OS, but where?

That place is the registry.

"MM" <kylix_is@yahoo.co.uk> wrote in message 
news:ao2l86dgeoj7ga4jq5c65gqr3a6of59lv6@4ax.com...
> On Fri, 10 Sep 2010 13:27:38 -0400, "Kevin Provance" <k@p.c> wrote:
>
>>
>>"Nobody" <nobody@nobody.com> wrote in message
>>news:i6d69s$qr2$1@speranza.aioe.org...
>>: I think VB tooltip is not using the common control tooltip, otherwise
>>every
>>: EXE made with VB would have a dependency on the common controls DLL.
>>
>>So?  That particular DLL is part of the Windows OS.
>
> While it is fairly straightforward to create one's own tooltip, which
> I've since done using Brad Martinez's tooltip example, it would be a
> lot easier simply to call a Windows API to reset the initial display
> for the inbuilt VBBubble tooltip. That 500ms initial delay must exist
> SOMEwhere in the OS, but where? It'll almost certainly be a Long.
>
> MM 

0
Reply J 9/10/2010 8:17:26 PM

On Fri, 10 Sep 2010 15:17:26 -0500, "J.C." <yoyo@nothanks.com> wrote:

>You can send a TTM_SETDELAYTIME to set the delay.
>
>SendMessage Handle, TTM_SETDELAYTIME, TTDT_AUTOPOP, 300
>
>>That 500ms initial delay must exist
>> SOMEwhere in the OS, but where?
>
>That place is the registry.

Do you know where?

MM
0
Reply MM 9/11/2010 7:08:14 AM

6 Replies
1115 Views

(page loaded in 0.084 seconds)

10/21/2014 9:12:29 PM


Reply: