SSRS Reports with datetime parameters
I have created one report in SSRS with two input parameters, FromDate and ToDate . Both fields i declared as DATETIME and i checked the option to allow NULL for bot开发者_StackOverflowh of these values . So in the reports one NULL CHECKBOX is coming along with this parameters. and when i click on the link , the report is automatically loading for NULL inputs ( without asking user to enter anything ). Is there any way to avoid this initial load for null values and to avoid the NULL CHECKBOX in the Report ....?
when you add a parameter to your report, you can specify that your parameter can give blank value, null value or multiple values. you must set this setting for your parameters in report.
if you have an application that pass parameters to your report, you can pass DateTime.MinValue as input parameter instead of null values.
uncheck the Allow Null value and Allow blank value and Check for the Allow multiple values only for the FromDate and ToDate parameters.
this can be accomplished at the report manager and not at the RDL. Once the RDL is uploaded and published ,highlight the report and click on the down arrow and go to Manage and then to Parameters. Uncheck the HasDefault and NULL attributes for the parameters and click on Apply. Now when you click on the report link, you can see the date parameters with blank values and the NULL unchecked.
精彩评论