Default printer for web

G

glbdev

Can anyone tell me how to get the name of the client's default printer
AND how to possibly pull up the Printer Dialog Box?

This is being used for Crystal Reports through the "PrintToPrinter"
method so the Javascript "window.print" code wouldn't help because it
prints the entire HTML page and not just the contents of the report.

I posted this in the "C#" group but no one seems interested in
answering it ... so I thought I'd try here.

Thanks!
- Gary
 
D

daniel

Private Sub Page_Load...
PrintThisPageLinkButton.Attributes.Add("onClick",
"javascript:print();return false;")
End Sub
 
G

glbdev

Thanks. Using this code does work to print the entire web page, but
how can I use it to print the Crystal report?

In other words, how can I tell C# to use the selected printer to print
the report in the CRViewer using the code
"oRpt.PrintToPrinter(1,false,0,0);"?

- Gary
 
G

glbdev

Thanks Daniel. I'm not sure if there is a reliable way to do it the
way my client wants. They'll just have to accept the fact that there
will be a pop-up pdf window.

Thanks for trying!
- Gary
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,770
Messages
2,569,583
Members
45,073
Latest member
DarinCeden

Latest Threads

Top