Crystal report in vb.net, printing problems

Please support our VB.NET advertiser: Intel Parallel Studio Home
Thread Solved

Join Date: Aug 2004
Posts: 12
Reputation: AK47 is an unknown quantity at this point 
Solved Threads: 0
AK47 AK47 is offline Offline
Newbie Poster

Crystal report in vb.net, printing problems

 
0
  #1
Aug 13th, 2004
I created a crystal report in vb.net 2003 that generates invoices. I need to be able to print this report to a Canon copy machine(with four paper drawers), but I can't select the paper drawer to print from at runtime, it has to print to the fourth drawer. I am using a ReportDocument object with the report source being Invoice.rpt within .NET.
Here is my current code for printing:

Public Sub PrintForm(ByVal s As String)
rdInvoice.RecordSelectionFormula = "trim({SOP10100.BACHNUMB}) = '" & s & "' and {SOP10100.SOPTYPE} in [4, 3]"
rdInvoice.Refresh()
rdInvoice.PrintOptions.PrinterName = "\\RAPCONT1\Canon iR3300 PS3"
rdInvoice.PrintOptions.PaperSource = PaperSource.Lower
rdInvoice.PrintToPrinter(1, False, 5, 5)
End Sub

Any ideas on how I can select at runtime the paper tray to print from?
Thanks in advance!
Reply With Quote Quick reply to this message  
Join Date: Sep 2004
Posts: 1
Reputation: john price is an unknown quantity at this point 
Solved Threads: 1
john price john price is offline Offline
Newbie Poster

Re: Crystal report in vb.net, printing problems

 
0
  #2
Sep 28th, 2004
Originally Posted by AK47
I created a crystal report in vb.net 2003 that generates invoices. I need to be able to print this report to a Canon copy machine(with four paper drawers), but I can't select the paper drawer to print from at runtime, it has to print to the fourth drawer. I am using a ReportDocument object with the report source being Invoice.rpt within .NET.
Here is my current code for printing:

Public Sub PrintForm(ByVal s As String)
rdInvoice.RecordSelectionFormula = "trim({SOP10100.BACHNUMB}) = '" & s & "' and {SOP10100.SOPTYPE} in [4, 3]"
rdInvoice.Refresh()
rdInvoice.PrintOptions.PrinterName = "\\RAPCONT1\Canon iR3300 PS3"
rdInvoice.PrintOptions.PaperSource = PaperSource.Lower
rdInvoice.PrintToPrinter(1, False, 5, 5)
End Sub



Any ideas on how I can select at runtime the paper tray to print from?
Thanks in advance!


Simplest method is to create a printer with the default properties you require and just switch to that printer when required.


hope this helps
Reply With Quote Quick reply to this message  
Join Date: Aug 2004
Posts: 12
Reputation: AK47 is an unknown quantity at this point 
Solved Threads: 0
AK47 AK47 is offline Offline
Newbie Poster

Re: Crystal report in vb.net, printing problems

 
0
  #3
Oct 8th, 2004
I'm speechless... I can't believe I didn't think of that!

Thanks!!
Reply With Quote Quick reply to this message  
Join Date: Apr 2008
Posts: 4
Reputation: janet_ss has a little shameless behaviour in the past 
Solved Threads: 0
janet_ss janet_ss is offline Offline
Newbie Poster

Re: Crystal report in vb.net, printing problems

 
0
  #4
Apr 8th, 2008
if you find difficulty in printing from Crystal report , u can export it as PDF or Excel format and print it.

its very easy.
Last edited by Narue; Jan 19th, 2009 at 11:32 am. Reason: snipped link
Reply With Quote Quick reply to this message  
Join Date: Jan 2009
Posts: 1
Reputation: gadepallisuresh is an unknown quantity at this point 
Solved Threads: 0
gadepallisuresh gadepallisuresh is offline Offline
Newbie Poster

Very Urgent Requirement.....Please Help...........

 
0
  #5
Jan 20th, 2009
I have a requirement:

I have a Parameterised Crystal Report.
I have one Button called btnView.
On btnClick event of that...

i want to Export the Crystal Report to PDF.

I have another Button called btnPrint.
On btnPrint event of that...

I want to convert to PDF and after that i want to print that PDF with Asp.net and C#.net.


Here the problem is i can able to send parameters to the Crystal Report but i am not able to Export the Parameterised Report in to PDF.

and also with Code ASP.Net and C#.Net i could not able to Print PDF directly with out showing it to the user
Reply With Quote Quick reply to this message  
Reply

This thread has been marked solved.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC