c# - How to open htm page in a browser window from windows forms application? -


in button click event handler of windows form, looks @ file path c:\dev\index.htm. need open file in browser window such ie or chrome. how can this? example appreciated.

thank you!

i'm not sure if understood problem right. if want open extern browser can use:

  system.diagnostics.process.start("c:\\dev\\index.htm"); 

if want show in form, have use ie through webbrowser. can load file via uri

yourbrowser.url=new uri("c:\\dev\\index.htm"); 

or load through reading htm file manual , setting document

yourbrowser.documenttext=system.io.file.readalltext("c:\\dev\\index.htm"); 

there several other methods, hope you.


Comments

Popular posts from this blog

android - MPAndroidChart - How to add Annotations or images to the chart -

javascript - Add class to another page attribute using URL id - Jquery -

firefox - Where is 'webgl.osmesalib' parameter? -