print html with vb.net

I have created a report that is formatted as html.  I need to print this using vb.net 2008.  The report is in memory, not a file or in a browser control.  Any guidance appreciated.

dhenderson12Asked:
Who is Participating?
 
AmbusyConnect With a Mentor Commented:
Create a System.Windows.Forms.WebBrowser.
Write the HTML to a file (in your temp directory).
specify the file as the source for the webbrowser.  
WebBrowser.Url = New Uri(wrkFileName)

Open in new window

print it using:
 WebBrowser.ShowPageSetupDialog()
WebBrowser.Print()

Open in new window

0
 
dhenderson12Author Commented:
good call.  actually you can just use the webbrowser.documenttext to load memory html and then just call the print() method.  

thx for the help
0
 
AmbusyCommented:
did not know about the documenttext, will try it. I saved my text first! thank you too.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.