Embedding WebKit and Gecko in VB .NET Application

WebKit  is a browser engine used on many applications and browsers such as Google Chrome, Safari, Adobe AIR, iCab, Epiphany (experimental), Konqueror (KHTML). It is an open – source browser engine ready to use for those who wants to embed this in their .net applications. On the other hand, Gecko is also a browser engine used by applications and browsers such as Firefox, Camino, Flock, Thunderbird, Seamonkey, Epiphany, NVU, Netscape, K-Meleon. It is also an open – source browser engine ready to be embedded into your .net applications, with the help of xulrunner, Gecko will be fully functional in your application. Here’s the sample image of my application that uses the mentioned browser engines.

 

STEPS (WebKit):

1. Copy all the files in the “WebKit.NET-0.4-bin-cairo\bin” (except the .exe)  folder into the “…\bin\Debug” of your project;

2. In Your Toolbox Right Click And Click “Choose Items…”. A New Form Will Show Up

3. In The .Net Framework Components tab click “Browse”.

4. Add The “WebkitBrowser.dll” from your Debug folder

5. Now you will have the webkit control in your toolbox. Drag it to your form and use it like a web browser component,    fill your form up with it and anchor it to all sides so it will get bigger and smaller when you resize the form.

6. Name The Webkit Browser: WebBrowser

7. Done.

 

STEPS (Gecko)

1. Download GeckoFX and xulrunner-1.9.1.16.en-US.win32.zip (http://releases.mozilla.org/pub/mozi…n-US.win32.zip).

2. Copy the files inside the “bin” folder of GeckoFX and extract xulrunner directly inside your “…\bin\Debug” of your project.

3. In Your Toolbox Right Click And Click “Choose Items…”. A New Form Will Show Up

4. In The .Net Framework Components tab click “Browse”.

5. Add The “Skyboun.Gecko.dll” from your Debug folder

6. Now you will have the Skybound.Gecko.Browser control in your toolbox. Drag it to your form and use it like a web browser component,    fill your form up with it and anchor it to all sides so it will get bigger and smaller when you resize the form.

7. Then place in your startup code this line of code: Skybound.Gecko.Xpcom.Initialize(Application.Startupath & “\xulrunner\”)

8. Done.

Enjoy everyone. Have a nice day. 🙂

Advertisements

~ by smush143 on December 28, 2010.

5 Responses to “Embedding WebKit and Gecko in VB .NET Application”

  1. Dear Smush,

    The post is awesome and helped me a lot.

    i am unable to click on any link inside this, for example i want to click on the submit button with an input tag such as following

    “”

    How to do that?

    Thanks

  2. Hi Soomya,

    If possible, please be precise on to where or what you are referring? And on what error had you encountered, if any.

    Thanks.

    – Smush 🙂

    • Hello Smush,

      Thank you for your reply.

      I need to click html tags inside a webpage, but these tags are without ID and invokemember function (present in default webbrowser of vb.net) is not available in webkit.

      Eg of tag is:

      How can i click this button as i have no clue of it.

      Thanks

  3. Tags are not being shown, so i am writing it down without “”

    Tag: INPUT
    value=Login
    type=submit

    Thanks

  4. Hello,
    I get Exception, HRESULT: 0xFFFFFFFF when I navigate it in code.
    I am using Krypton Suite (Krypton Navigator, etc.) as my form and design.
    How do I fix this?
    Thank you.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: