DaniWeb IT Discussion Community

DaniWeb IT Discussion Community (http://www.daniweb.com/forums/index.php)
-   VB.NET (http://www.daniweb.com/forums/forum58.html)
-   -   Crystal report (http://www.daniweb.com/forums/thread113697.html)

Kartikey Mar 13th, 2008 7:49 am
Crystal report
 
hello sir ,

i am getting problem with crystal report
VB.net and SQL Server

i want selected values to be printed in crystal report
so i have written sql query for that .


dataset shows selected values but crystal report shows all data in database


Please help me .
following is th e code :-


Dim dacrupt As SqlDataAdapter = New SqlDataAdapter(strcryst, myconn)
myconn.Open()
dacrupt.Fill(dscryst, "t_candidates")
myconn.Close()
MsgBox(dscryst.Tables("t_candidates").Rows.Count)
str100 = "new resume"
Dim objcryst As New Form1
objcryst.Show()





Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
CrystalReportViewer1.RefreshReport()
Dim myconn As SqlConnection = New _
SqlConnection("server=;database=project3;uid=;pwd=")
Select Case str100
Case "new resume"
newresume()
dscryst.Clear()
End Select
End Sub
Private Sub newresume()
Dim cr As New CrystalReport1
cr.SetDataSource(dscryst)

MsgBox(dscryst.Tables("t_candidates").Rows.Count)

CrystalReportViewer1.ReportSource = cr
End Sub

Jx_Man Mar 13th, 2008 1:58 pm
Re: Crystal report
 
r u sure doing the right way when you make the report form at first time (using wizard).

gomathinayagam Nov 26th, 2008 7:26 am
Re: Crystal report
 
how can filter the field in crystal report at run time in vb.net

sierrainfo Dec 4th, 2008 3:08 am
Re: Crystal report
 
See the following links. Hope it will help you.

http://systems.bus.ucf.edu/lwest/cou...ns/reports.htm

http://www.vbdotnetheaven.com/Upload...thXmlInVB.aspx


All times are GMT -4. The time now is 2:39 am.

Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2009 DaniWeb® LLC