|
-
Jul 28th, 2004, 12:34 AM
#1
Thread Starter
New Member
Parameter value from combo to CRystal Report How???
Hi There, I want to devlop a report in my project in which i want the user to select a value from the combo box and the value will be passed to the crystal report to generate the report.
The code that i have been using is as follows
Private Sub cmdViewrpt_Click()
If cmbMemType.Text = "Faculty" Then
s = "{tab_member_type.member_type}='" & cmbMemType.Text & "' and {tab_issue_return.returned_on}='Outstanding'"
End If
If cmbMemType.Text = "Faculty" Then
s = "{tab_member_type.member_type}='" & cmbMemType.Text & "' and {tab_issue_return.returned_on}='Outstanding'"
ElseIf cmbMemType.Text = "Staff" Then
s = "{tab_member_type.member_type}='" & cmbMemType.Text & "' and {tab_issue_return.returned_on}='Outstanding'"
ElseIf cmbMemType.Text = "Others" Then
s = "{tab_member_type.member_type}='" & cmbMemType.Text & "' and {tab_issue_return.returned_on}='Outstanding'"
End If
cryOutstandingMem.RecordSelectionFormula = s
cryOutstandingMem.DiscardSavedData
Report.EnableParameterPrompting = False
Report.ParameterFields.GetItemByName("outstandingMem").AddCurrentValue cmbMemType.Text
Report.ParameterFields.Item(1).Value = cmbMemType.Text
CRViewer91.ReportSource = Report
CRViewer91.ViewReport
CRViewer91.Refresh
End Sub
Please Help me out
Thanking u in Advance
NIELSH VAKNALLI
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|