Friday, March 22, 2013 12:27 PM
I have a report where I write the name of the sales person above the data table depending on what sales district i pick as a parameter. It is also allowed to pick more than one district, but when that happens, the report will always show the name of the sales person for the first district, but the data in the table will show for all the sales districts that have been choosen.
Now, I would like my report to not display anything in the name field if the parameter contains more than one district. How can I do that?
Friday, March 22, 2013 12:37 PM
You can use the Count() function of the parameter to get the count of selected parameter value; so in an expression you can return the name or an empty string depending on this value:
Olaf HelperBlog Xing
Friday, March 22, 2013 12:55 PM
i guess you have a Multi Value Parameter. To get the String value of a Multi Value Parameter you need to join the Values:
Example: Your Parameter hast the values
Use: Join(Parameter!P1.Value, ", ") and you will get: "Mary, Alex, John" in your Field
Hope this helps.
Friday, March 22, 2013 1:01 PM
Hello both Sven and Olaf and thank you for your help. I tried Olafs suggestion and it worked exactely as I wanted. Then I read Svens answer and changed my qery accordingly and that worked also. In the end I went for Olafs solution.