WebBrowser Control Part II#

As said in my previous post the SDF WebBrowser Control wraps HTMLView.dll which PocketIE uses.  On WindowsCE the SDF WebBrowser control will not browse to a http:// URLs but will work on a PocketPC.  .NET Compact Framework 2.0 has a standard WebBrowser control similar to the WebBrowser control in the Smart Device Framework. .NETCF 2.0 WebBrowser Control will work on both PocketPC and WindowsCE, but on WindowsCE you will need the Pro License and have the control as part of your OS image.

In my previous post I stated you could wrap IWebBrowser2.  Well, IWebBrowser2 is actually an interface so what you will have to wrap is shdocvw.dll.  IWebBrowser2 allows your application to create an instance of the WebBrowser control using ActiveX.  Of course this is all done in C++ using Embedded Visual C.

Sergey Bogdanov has actually done a lot of the work to get web browsing working in WindowsCE.  Download the sample project here

Here are some update links to get you started if you want some more technical information on the browser in CE. 


Wednesday, September 14, 2005 10:01:06 AM (Eastern Daylight Time, UTC-04:00) #    Comments [1]  | 

 

OpenNETCF SDF WebBrowser Control#

The OpenNETCF SDF has a WebBrowser control under the OpenNETCF.Windows.Forms namespace.  There have been some "issues" with the WebBrowser control and using it on a WindowsCE device using .NETCF 1.0.  The WebBrowser control works on Pocket PC devices but does have limited functionality on Windows CE devices. 

First some background on the control.  The SDF WebBrowser control is a wrapper to the HTMLView.dll that come with PocketPCs.  This gives the functionality to browse URLs as long as you have connectivity.  For more technical information see here.  The SDF WebBrowser control wraps this functionality so it can be used in managed code and has design time support.  

On windows CE devices you cannot browse to external URLs but you can browse to files on the local device.  For example if you set the URL property on the WebBrowser control to file://[YOUR FILE] you should be able to see your file.  The reason for this is, WindowsCE uses HTMLView for Help files so it has limited functionality on a WindowsCE device. 

To have a full blown WebBrowser on windows CE there are a few things you have to do.  First, you have to pay for a Pro License which includes a full blown IE browser.  You may be able to get the Core license which has a scaled down version of IE but I'm not 100% sure.  Check here for more details or contact your distribution partner for more information. Second, you have to wrap IWebBrowser2 to be p/invoked from managed code and to display the unmanaged browser window within your unmanaged application.  This is not an easy task but is possible.

So basically, the OpenNETCF SDF WebBrowser control is fully functional and does not have any "bugs" or "issues" since we rely on the underlying OS.

Here are a few links to that may be of help if you attempt to wrap IWebBrowser2.  NOTE: There is an article on MSDN that goes through a C++ sample which is useful. I don't have the link but will post if I find it.

WINCE
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wceshdoc/html/ceconAddingInternetBrowsingFunctionalityToYourApplication.asp
http://msdn.microsoft.com/library/en-us/dnce30/html/iece30.asp
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnnetcomp/html/HostingANativeWindowsControl.asp

Desktop - http://msdn.microsoft.com/workshop/browser/webbrowser/browser_control_node_entry.asp


Tuesday, September 13, 2005 3:06:53 PM (Eastern Daylight Time, UTC-04:00) #    Comments [0]  | 

 

All content © 2008, Mark Arteaga
Related Sites
Archives
Sitemap
Disclaimer

Powered by: newtelligence dasBlog 1.9.7174.0

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

Send mail to the author(s) E-mail

Theme design by Jelle Druyts