Solved

Making hints show longer

Posted on 1998-04-29
4
206 Views
Last Modified: 2010-04-06
Hi,
I need to display the hints in my program for longer than
they do now. I need them to show for 6 seconds.
What do i need to do?
MAXcom
maxcom@theoffice.net
0
Comment
Question by:MAXcom
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 5

Accepted Solution

by:
JimBob091197 earned 100 total points
ID: 1339493
Hi

You must use the Application.HintHidePause property, which defaults to 2500 ms.

E.g. for 6 seconds:
Application.HintHidePause := 6000;

Cheers,
JB
0
 

Author Comment

by:MAXcom
ID: 1339494
Thanks, is there any way i can update the hint while its being shown? And display the new changes without having the user move the mouse off and then back onto the object.
0
 
LVL 5

Expert Comment

by:JimBob091197
ID: 1339495
Hi

I don't think there is a way to change a hint while it's being shown.  You need to call TApplication.CancelHint (no problem there) and then TApplication.ActivateHint.  Unfortunately Borland (in their infinite wisdom!) have made ActivateHint a private method, so it can only be called by TApplication, and not from the outside.

JB
0
 
LVL 5

Expert Comment

by:JimBob091197
ID: 1339496
Hi MAXCom

I have been playing around, and have a way to change the hint with minimal flicker.  (Unfortunately it does flicker a little as the hint changes.)

// - - - START OF CODE - - -
var
  OldPause: Integer;
begin
  OldPause := Application.HintPause;
  Application.HintPause := 0;
  Application.CancelHint;
  MyControl.Hint := 'This is a new hint';
  Application.ProcessMessages;
  Application.HintPause := OldPause;
end;
// - - - END OF CODE - - -

Cheers,
JB
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Firemonkey android show image from resource ? 1 72
how to resize animated Gif image in delphi ? 1 62
DBCtrlGrid, Delphi, Scroll 8 87
shape, triangle, dbctrlgrid 3 47
The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question