Possible Duplicates:
Disable browser's back button
How do I disable the F5 refresh on the browser?
Hi,
I created an application in C# that will download data from the internet (and this is done one time only) and put it in a webbrowser and this data should be static. I want to know if there is a way to disable the F5 key from doing a refresh?
I tried injecting javascript to disable F5 but it will still refresh the webbrowser.
You cannot disable F5 (or other browser shortcut keys) via JavaScript.
Setting the
WebBrowserShortcutsEnabledproperty of theWebBrowsercontrol tofalseshould accomplish what you’re trying to do.