-
Private Sub Command2_Click()
Dim strSQL As String
Dim strSQL2 As String
Dim strSQL3 As String
Dim strSQL4 As String
Dim strSQL5 As String
With ActiveReport1
strSQL = "select * from projectinfo where requesttitle ='" & Combo2.Text & "';"
strSQL2 = "select * from projectinfo where requestor ='" & Combo3.Text & "';"
strSQL3 = "select * from projectinfo where Priority ='" & Combo4.Text & "';"
strSQL4 = "select * from projectinfo where Status ='" & Combo5.Text & "';"
strSQL5 = "select * from projectinfo where requesttype ='" & Combo6.Text & "';"
'sSQL = "select * from projectinfo where requesttitle like 'Bond Analizer'"
myclass.GetMyData strSQL
myclass.GetMyData strSQL2
myclass.GetMyData strSQL3
myclass.GetMyData strSQL4
myclass.GetMyData strSQL5
Set .dbReport.Recordset = myclass.rsMyData
.txtapplication.DataField = "requesttitle"
.Field5.DataField = "requestor"
.Field1.DataField = "Priority"
.Field2.DataField = "Status"
.Field3.DataField = "RequestType"
.Field7.DataField = "Completed"
.Field6.DataField = "devname"
.Run False
.Show
End With
End Sub
when I try to retrieve a different selection on my dropdown combo box I get a blank report..it worked for one field but the oother's won't come up..
Is it possible I need a refresh command to re-execute a SQL statement?
-
HEEEEEEEEEEEEELLLLLLLLLLLLLLLLLPPPPPPPPPPPPP
-
-
Ok ..I've made some modifications on the SQL script....
But no cigar...
With ActiveReport1
strSQL = "select * from projectinfo"
strSQL = strSQL & "where requesttitle = " & Combo2.Text & "';"
strSQL = strSQL & "where requestor = " & Combo3.Text & "';"
strSQL = strSQL & "where Priority = " & Combo4.Text & "';"
strSQL = strSQL & "where status = " & Combo5.Text & "';"
strSQL = strSQL & "where requesttype = " & Combo6.Text & "';"
I thought this script would define the fields chosen..but nothing.