I am using the MS ReportViewer in C# to render reports. My usage and helpers all work very well and I can generate reports and set parameters just fine... except if the parameter is typed as a non string in the RDLC
Example: RDLC parameter IsMyFavorite is typed as Boolean.
parametersCollection.Add(new ReportParameter("IsMyFavorite", boolean.FalseString, false));
reportViewer.LocalReport.SetParameters(parametersCollection);
reportViewer.LocalReport.Refresh();
inside my RDLC I use the parameter to hide a textbox my hidden expression is =Parameters!IsMyFavorite.Value
When I render to PDF, I get an error saying I am missing a parameter... that is not true. And I understand that I am passing a string into a Boolean and that it is a mismatch. Thus, it maybe true that I am missing the parameter as a Boolean. But using C#, how do I pass the new ReportParameter as a Boolean?