views:

538

answers:

2

Hi There, I need to be able to display html files that are stored locally on device using a WebBrowser control on a windows form.

I simply point the WebBrowser to page like so : ctrlBrowser.Url = new Uri("file://\\My Documents\test.html");

The pages load perfectly into control excepet for a windows mobile 6.1 device that has oper browser also installed. Each time the above code runs, the page loads but it loads in a newly launched opera browser screen. I need to use WebBrowser control to trap nagivation events etc but cannot seem to find a way to foce page to load in control when opera is installed.

Your thoughs are much appreciated as Im agains a brick wall on this one.

Many thanks tony

+1  A: 

It's a strange side effect of the Opera browser being the default (I believe it happens if you install Opera on any WinMo device in fact). A workaround is discussed here.

ctacke
A: 

We came across this in our WM 6 program. It is due to Opera being the default system browser for the device. The workround (modifying the device registry) given by @ctacke is reputed to work correctly, but alternatively you can open Opera and use the preferences to un-set it as the default browser. We chose the latter aproach, although you could combine the two and ask the user to change their preferences if the registry is set to have Opera as default.

Stevo3000