Guest_imported
New member
- Jan 1, 1970
- 0
I have a Visual Basic 5.0 application that has 1 report under it.
The version of cr is 4.6..
The problem is that when i have tryed the Sql statement from Crystal Reports it works fine But when i pass it through Vb it does not find the data that is required?
The code i am writing is the following:
With frmPersonnel.CrystalReport1
.ReportFileName = App.Path & "\Test.rpt"
.WindowTitle = "Test Report"
If Me.lstName.Text <> "" Then
.SqlQuery = "SELECT tblDisipline_history.Personnel_Name From tblDisipline_history WHERE tbldisipline_History.Personnel_Name " = frmPersonnel.lstName.Text
.Destination = crptToWindow
.PrintReport
Exit Sub
End If
End With
hope you can help with this.
Many thanks
Stephen Rattray..
The version of cr is 4.6..
The problem is that when i have tryed the Sql statement from Crystal Reports it works fine But when i pass it through Vb it does not find the data that is required?
The code i am writing is the following:
With frmPersonnel.CrystalReport1
.ReportFileName = App.Path & "\Test.rpt"
.WindowTitle = "Test Report"
If Me.lstName.Text <> "" Then
.SqlQuery = "SELECT tblDisipline_history.Personnel_Name From tblDisipline_history WHERE tbldisipline_History.Personnel_Name " = frmPersonnel.lstName.Text
.Destination = crptToWindow
.PrintReport
Exit Sub
End If
End With
hope you can help with this.
Many thanks
Stephen Rattray..