Click here to Skip to main content
15,886,362 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

I am capturing function keys in my dialog based MFC/C++ application by overriding CWinApp::PreTranslateMessage(). This works fine for F2 to F9 but F1 is still trying to open help (although I do get the keypress also).

I handle ON_WM_HELPINFO() in my main dialog and this appeared to work initially but it has since stopped (not sure at what point and what I did to break it). I have added controls to my dialog so maybe this is why it stopped working?

Does anyone have any suggestions as to how I can stop F1 from opening help within my application?

Thanks
Posted

1 solution

Its OK, I think I got it. I just removed the following from my message map and it seems to have worked.

ON_COMMAND(ID_HELP, &CWinApp::OnHelp)
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900