Reputation: 613
Scenario is simple:
If you add a web browser in visual studio it adds IE. If you are logged somewhere with IE it keeps you authenticated like reading cookies or sessions. Web browser component and IE is the same.
So, is there a way to access firefox from c# (like web browser or some way) and lets say load a page and get the html of this page? Or load a page, fill a textbox and click a button, all these via c#?
Upvotes: 2
Views: 2090
Reputation: 6451
There is no way of using Firefox from within C# by default. You do have a few options however, if you want to do something with it's rendering engine for example you could use GeckoFX to give yourself a nice C# wrapped GECKO engine.
If it involves testing / automation then you could look into WatiN which supports various browsers or even UI automation.
Upvotes: 2
Reputation: 22266
Selenium is a browser automation framework that will let you perform these tasks using C#. There's a driver for Firefox that works very well.
Upvotes: 5