Click here to Skip to main content
15,894,343 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hello friends,

here i need your help.
Actually i want to print a pass in my application through crystal report and cant get any option to set the page size.

Actually width of the print should be 4.25 inches and height should be 5 inches.

Please get me out of this friends..!


Thanks
Posted

Check This Link
1.
http://www.c-sharpcorner.com/UploadFile/sushmita_kumari/Report102282006060013AM/Report1.aspx?ArticleID=70bc6bcc-8f4b-4db4-8c63-0dd8b3300203[^]

Or
C#
System.Drawing.Printing.PaperSize pr = new System.Drawing.Printing.PaperSize("B4 (JIS)", 10, 6);

put this above stated code after providing the report source...

or if u want to do it from design mode then right click on the crystal report(.rpt file) select design then printer option. from there you can provide your required settings..
Hope this helps......
 
Share this answer
 
Comments
Ravi Tuvar 8-Feb-12 5:14am    
Thanks aniket,

i tried this solution but it can not convert from System.Drawing.Printing.PaperSize to CrystalRpt.PrintOptions.PaperSize..
so have u any tip for this case?
Aniket Yadav 8-Feb-12 5:26am    
I have checked the above code and its working fine with me.
 
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