borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder

AndreaVB | Forum | News | Downloads | Register | Help | Member List | Statistics | Search | PM | Profile

Print This Topic
Previous Topic (Invalid Report Source)Next Topic (print report as per single transaction in single page) New Topic New Poll Post Reply
AndreaVB Forum : Reporting tools : How to start coding to take printout?
Poster Message
sneha
Level: Scholar

Registered: 28-03-2006
Posts: 29

icon How to start coding to take printout?

Hi,

I have one command "cmdprint" on a form and "CrystalActiveXReportViewer1" and "Report1.rpt". I have written the code like below:


Private Sub CrystalActiveXReportViewer1_CloseButtonClicked(UseDefault As Boolean)
Cr.ReportFileName = "Report1.rpt"
Cr.Action = 1
End Sub
Private Sub cmdprint_click()
Cr.ReportFileName = App.Path & "Report1.rpt"
Cr.DiscardSavedData = True
Cr.Action = 1
Cr.PageZoom (85)

End Sub


When I try to click on cmdprint button ...It shows error : "Object required" and points to the followine line:
"Cr.ReportFileName = App.Path & "Report1.rpt"

I am using crystal reports XI

Please help.


____________________________
Sneha

10-05-2006 at 06:41 PM
View Profile Send Email to User Show All Posts | Quote Reply
AndreaVB Forum : Reporting tools : How to start coding to take printout?
Previous Topic (Invalid Report Source)Next Topic (print report as per single transaction in single page) New Topic New Poll Post Reply
Surf To:


Not Logged In? Username: Password: Lost your password?
Partners: Download Actual Software | Free Software Download
borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2007 Andrea Tincaniborder