0

Is there a way to parse html content which contains css and javascript, and then print it without having the computer to display the print dialog using c# desktop program?

The html may contain javascript that manipulate the DOM. For example :

<html><body><h1>Title</h1><script>document.write(Math.random())</script></body></html>

1 Answers1

1

You want to load it into a WebBrowser object and then call the Print method

Although if you don't like IE you might want to look at Replacing .NET WebBrowser control with a better browser, like Chrome? for alternatives.

PhilS
  • 624
  • 3
  • 5