• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 148
  • Last Modified:

Crystal report is not working with VB

Hello Friends
I m using Crystal report7 in visual basic.But i m not able to load the report ,when i click on the Button.
How i show my report when i click on the button of form .
0
hansol1
Asked:
hansol1
  • 2
  • 2
2 Solutions
 
DabasCommented:
It would help if you would provide more information as to what you have tried to do.

Assuming you have named your report control crw, and your button btnReport, and that you have filled the properties of the control with the ReportFileName and other attributes, then all you need to do is to have the following line of code:

Public Sub btnReport_Click()
   crw.Action = 1
End Sub
0
 
mlmccCommented:
That will work if you are using the OCX to display the report.  If you upgraded to the ActiveX or RDC

 crw.PreviewReport

mlmcc
0
 
CleanupPingCommented:
hansol1:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
EXPERTS:
Post your closing recommendations!  No comment means you don't care.
0
 
DabasCommented:
Mod:

Suggest split between both experts

Dabas
0
 
mlmccCommented:
Agree with dabas
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now