Delphi 2007 - Faulty Help Logic, or "How to ask for help"

Well, it's been a busy day, trying to figure out why some users would get the proper options when pressing F1 over shellexecute and others would require that ShellAPI was already declared in the uses clause for the help to work out...

A few Delphi users contributed with their input on the wrong assumption (by all of us!) that it was something related to each user's particular configuration. It turns out, as Craig Stuntz discovered, that it's a question of where you type shellexecute!

That is, if you create a new VCL forms project, then double click the form to create a method and type shellexecute there, pressing F1 will yield a famous message of "No help found for (none)"; if, on the other hand, you type shellexecute on somewhere where it will be illegal for it to be, say, after the uses clause, pressing F1 over shellexecute will show you the proper help!

So, if you get another "No help found for (none)", try typing that keyword on, say, the end of the file right after end.

I did some more tests and found other alternatives as well:
New (empty) text file->type it there, press F1 and it works.

But the easiest way to do it: just type // before the keyword you're looking for help! :)

This includes other keywords such as for, div, array, etc...

the above tricks only work if the message is "No help found for (none)"; if you ask for help on some keyword and instead get "No help found for context", then these tricks will not work...

1 comment:

Fernando Madruga said...

Chris Bensen blogged about the causes for this issue.