Link to home
Start Free TrialLog in
Avatar of ashish_me2
ashish_me2

asked on

Printing HTML documents in C#

Hi,

We have a module in a C# Windows application that prints Images and Plain Text  to the default printer using the PrintDocument class.

We need to extend the functionality to allow printing of HTML files also but are facing a problem. If the HTML file is read as a plain text file, it is sent to the printer as the actual HTML markup with all HTML tags and script on the printed document instead of the rendered view that we get on the browser.

Am looking for any pointers to solve this problem….

Avatar of armoghan
armoghan
Flag of Pakistan image

see the following example for printing. This is a clone for IE in VB.NET
http://www.planet-source-code.com/vb/scripts/ShowCode.asp?txtCodeId=1953&lngWId=10
ASKER CERTIFIED SOLUTION
Avatar of _kiwi_
_kiwi_
Flag of France image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of nhewitt21
nhewitt21

There is already a similar question to this with an accepted answer:
https://www.experts-exchange.com/questions/21056137/Printing-HTML-or-DOC-documents.html
Avatar of ashish_me2

ASKER

Thanx all of you for the valuable inputs.

-Ashish.
=====