CR.Reset
CR.ReportFileName = "StudentInformation.rpt"
CR.SelectionFormula = "{SPINF.GRNO}=" & Me.txtGRNo.Text & "" And "{SPINF.CMBCAT}=" & Me.cmbCat.Text & ""
CR.Action = 1

m trying to passing two parameter for cr..! bt it always shows the error type mis match.! plz help me

Mismatch refers to an incorrect field name in your table, incorrect control name, the use of say "Text1.Caption" and not "Text1.Text", incorrect string value etc.

Post your full code here and where the error occurs.

dat is the full code sir..!

here is the error occur

CR.SelectionFormula = "{SPINF.GRNO}=" & Me.txtGRNo.Text & "" And "{SPINF.CMBCAT}=" & Me.cmbCat.Text & ""

i dunt know the rite method to pass two parameter in crystal report

CR.SelectionFormula = "{SPINF.GRNO}=" & Me.txtGRNo.Text & "" And "{SPINF.CMBCAT}=" & Me.cmbCat.Text & ""

Change to this and try.

CR.SelectionFormula = "{SPINF.GRNO} = '" & Me.txtGRNo.Text & "'" And "{SPINF.CMBCAT} = '" & Me.cmbCat.Text & "'"

Have a look at this tutorial on Crystal reports and the "SelectionFormula" statement over HERE.

Edited 6 Years Ago by AndreRet: n/a

This line work for me..! thanx andreRat

VReport.SelectionFormula = "{SPINF.GRNO}=" & Me.txtGRNo.Text & " And {SPINF.GRCAT}='" & Me.cmbCat.Text & "'"
This question has already been answered. Start a new discussion instead.