Solved

Help Screens

Posted on 1998-04-07
1
148 Views
Last Modified: 2010-04-06
Hi there,
    Is there an easy way to create and implement help screens for a Delphi 1 application? I've never done it before so any help would be much apprecited.

Thanks, Linda
0
Comment
Question by:LindaMacy
1 Comment
 
LVL 1

Accepted Solution

by:
Edo082297 earned 20 total points
ID: 1361325
Hi Linda,

The TApplication variable, which every Delphi application has,  contains a property called HelpFile. This is a string that contains the path to a help file associated with the application. Each form, which is derived from TWinControl, has another property called HelpContext. HelpContext provides a context number for use in calling context-sensitive online Help. This means that for individual screens you can have custom help display. You could also call the context menu help by trapping the F1 key OnKeyPress for the form (the form must have focus). To trap a key, do this:

procedure TForm1.FormKeyPress(Sender: TObject; var Key: Char);
begin
  if Key in [VK_F1] then
    MessageDlg('F1 has been pressed', mtInformation, [mbOK], 0);
end;

If you wanted to implement searching on the help file, try this:

The parameter for this command should be a PChar (cast to a
longint to circumvent typechecking) that contains the string on
which you'd like to search.  The example below uses an empty string, which invokes the "Search" dialog and leaves the edit control in the dialog empty, just like when you hit "Find" in Delphi help.

procedure TForm1.SearchHelp;var  P: PChar;
begin
  Application.HelpFile := 'c:\delphi\bin\delphi.hlp';  
  P := StrNew('');
  Application.HelpCommand(Help_PartialKey, longint(P));
  StrDispose(P);
end;

Now that you have some utility, you must create the help file! Just go to virtually any good shareware site, and download a recommended help authoring package. They are intuitive and easy to use!

HTH!



0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
select query - oracle 16 100
creating threads in delphi 1 132
TEMBEDDEDWB how can i change its user agent ? 8 70
Delphi and Access based Enumeration 9 70
A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…

839 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