Solved

Making hints show longer

Posted on 1998-04-29
4
203 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
  • 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

Problems using Powershell and Active Directory?

Managing Active Directory does not always have to be complicated.  If you are spending more time trying instead of doing, then it's time to look at something else. For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Windows Drag & Drop Location 2 100
Intraweb submit form as a POST request 4 303
Installshield for Embarcadero EX 10.1 Berlin 4 40
Multi-layered image in FireMonkey 9 34
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…

770 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