Trap PF key events

  • Thread starter Thread starter Bill
  • Start date Start date
Sorry, should have put it in quotes, "PF1 event".
The question is: can I trap in the code sheet of
a form when the user presses PF1. If not, then
Access will launch its own HTML Help file.

There seems to be a problem with the API when
user help is launched via the use of context ID's.
I want to code to the API myself to see if I can
identify the problem as being in Access or if the
problem is in the HTML viewer.

Purely for testing purposes, I can obviously use
a command button or other type of control. I'm
just looking ahead to the potential situation wherein
I'll need a work-around.

Bill
 
I just finished testing an invocation of the HTML Help
API with the use of a command button and its click-event
in one of my forms. What fails consistently when using
the forms HelpContextID in Access 2000 works perfectly
if I call the API myself from code.

So, I'm back to my question about being able to trap a
user's use of PF1 to obtain help. I'd really like to mask
the Access problem by running my code versus the
path that would otherwise be taken using the forms
current value of HelpContextID.

I just don't want to put command buttons or other object
controls on all of my forms.

Bill
 
Create an AutoKeys macro that remaps what F1 does to run your own function
instead.
 
Douglas,
Looks like AutoKeys will get the job done nicely. I've
remapped {F1} to run a module that will call the HTML
API. I think my only remaining question is how do I
access the HelpContextID property of the object that
currently has the focus? And, if that object has no ID
assigned, then the HelpContextID of the form or report
that contains that control.

I just need to mimic what Access does.

Thanks,
Bill
 
Back
Top