How we pass multiple values as dynamic parameter in Fast Report
Hi,
How we pass multiple values as parameter in Fast Report
I want to pass two value as report parameter , so that multiple record display.
Ex: We have 4 doctors in table
1-A
2-B
3-C
4-D
We have 5 Patient with associated doctors in patient table
1-A1-A
2-A2-A
3-A3-B
4-A4-C
5-A5-B
So i want to display the record for all patient which associated with A,B Doctor.
parameter code concatenate A,B but in report pass only B, So how we pass dynamically Parameter as A,B.
dynamicparameter = "A,B"
Report.SetParameterValue("code", dynamicparameter)
But if we pass parameter as below then result proper.
Report.SetParameterValue("code", "A,B")
How we pass multiple values as parameter in Fast Report
I want to pass two value as report parameter , so that multiple record display.
Ex: We have 4 doctors in table
1-A
2-B
3-C
4-D
We have 5 Patient with associated doctors in patient table
1-A1-A
2-A2-A
3-A3-B
4-A4-C
5-A5-B
So i want to display the record for all patient which associated with A,B Doctor.
parameter code concatenate A,B but in report pass only B, So how we pass dynamically Parameter as A,B.
dynamicparameter = "A,B"
Report.SetParameterValue("code", dynamicparameter)
But if we pass parameter as below then result proper.
Report.SetParameterValue("code", "A,B")
Comments
you also may pass object in Report.SetParameterValue
for example:
in your app.exe
passing object :
in your frx file
you must set reference to app.exe and create script :
then pass :
DataTransferObject parameter = new DataTransferObject() { Id = 1, Name = "Test" };
report.SetParameterValue("Parameter", parameter);
in frx file, define a parameter with name = 'Parameter' and datatype = null, then create a script: