I want to display a webpage in a WebBroswer in my winforms application. I however want to use some custom css to change how the page looks. Is it possible to attach a style sheet and edit the html page you are viewing?
-
maybe you can open webpage with javascript:void(document.designMode="on") so this will force page to be edited.adt– adt2011-02-27 21:34:49 +00:00Commented Feb 27, 2011 at 21:34
-
1possible duplicate of winforms html editorHans Passant– Hans Passant2011-02-27 21:39:56 +00:00Commented Feb 27, 2011 at 21:39
2 Answers
You can use this web control http://www.codeproject.com/KB/miscctrl/csEXWB.aspx and save it as a web page and load and you can show the source in another text box , once changes are made you can save to a temp file and load it. There is an option to view local file.
Comments
I don't think that kind of thing is supported.. but anyway that would be a horrible thing to do. you may end-up interfering with the CSS used by the client page.
Have you ever seen your browser override your CSS used by page and say i want to show it this way. (I know development tools like firebug,etc do it)