Click here to Skip to main content
15,559,491 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi,

I have developed a web App. and i publshlised in IIS(server). when i go to access that web App on another PC which has connected to printer. the report shows well but the problem is that:

When I press the print icon on the report , 1 pop opens and it asks me to choose all pages or select page range when I press on "Ok" on this page it then opens the report in pdf file and then I click on print button on pdf and then print comes.

I dont want that User shud see the pdf file..
I want that when User click on report then without any further popup the Print should come
Posted
Updated 30-Sep-11 7:09am
v2

Try PrintToPrinter function as mentioned in this article:
Choosing a printer when printing from Crystal Reports in C#[^]
 
Share this answer
 
Comments
bkthebest 1-Oct-11 1:06am    
hello shukla ji,
i tried with "PrintToPrinter" but it works only at client machine....
i want that user give print command from their own pc while the application is published on server
XML
<head runat="server">
<script type="text/javascript">
window.print();
</script>
    <title>Untitled Page</title>
    </head>


just use the above code in the page which has CrystalReportViewer.....it will print on client machine
and if the font size of report is small then increase the font of report fields...
simple...
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900