Display text if No Parameter value selected
I am running a report and selecting certain parameters, sometimes I don't select any parameters and if this happens all records are displayed at the top of the Report. If I select a Value for Area it will show the value on the report but if I don't selecta
value then text like "All Areas Selected" is displayed instead i.e.
Area: "All Areas Selected"
Applied From: 01/01/2012
Applied To: 18/05/2012
Status: "All Status Selected"
In the above I have selected nothing for Area and Status but I have selected dates From and To. I want to have something like the above displyed at the top of the report.
Anyone know how this can be achieved?
Thanks.
May 18th, 2012 9:37am
Hi,
Yes you can do this quite easily in SSRS.
If you're wanting to display the data as you've typed it above, then you'd want to drag a text box on to the canvas.
From there, double left click into the text box, then type "Area: " - then right click once and select "Create Placeholder..." which will take you into Placeholder Properties.
Click the "Fx" next to the Value text box, select Parameters in the bottom left window that pops up. Then you can use the value of the parameter in the place holder.
Rinse and repeat for each value you want to add.Zach Stagers - scratchbox.co.uk
MCITP: Database Developer 2008
Remember to Mark as Answer and Vote as Helpful
Free Windows Admin Tool Kit Click here and download it now
May 18th, 2012 9:54am
Thanks for the reply Zach but I just can't get this to work. How is it that I can have in the text "All Areas Selected" if I don't select a value for the report paramater but if I selec 'A' then 'A' is displayed?
May 18th, 2012 10:03am
Have you followed my instructions above and it still isn't working?
When doing it the way I've suggested, you should be able to use the value without any issues.
I've done it this way in the past multiple times with NULLable parameters as I believe you're trying to do.
Maybe these will help you?
http://technet.microsoft.com/en-us/library/ms345237.aspx
http://plataan.typepad.com/microsoftdynamics/2009/08/reporting-services-2008-placeholder.htmlZach Stagers - scratchbox.co.uk
MCITP: Database Developer 2008
Remember to Mark as Answer and Vote as Helpful
Free Windows Admin Tool Kit Click here and download it now
May 18th, 2012 10:15am
Hi Zach, I followed your instructions.
I can't find any parameter called Area in the parameters list ....
I am trying to mimic this as it has been done in access using teh following expression:
=Nz([Forms]![frmStatusDialog].[Area],"All Areas Selected")
Any ideas?
May 18th, 2012 10:26am
Hi,
What are you using to build the report out of interest?Zach Stagers - scratchbox.co.uk
MCITP: Database Developer 2008
Remember to Mark as Answer and Vote as Helpful
Free Windows Admin Tool Kit Click here and download it now
May 18th, 2012 10:37am
I am initially creating the reports in CRM 2011 and exporting them and then modifying them in BIDS 2008.
I then import them back into CRM and run them from there.
I know its not the most straight forward reporting application to build.
May 18th, 2012 10:44am
Could you try what I've suggested in BIDS rather than CRM?
It should be as easy as using "=Parameters!Area.Value" in your placeholder expression.
I've never actually used CRM to build an SSRS report myself...
Zach Stagers - scratchbox.co.uk
MCITP: Database Developer 2008
Remember to Mark as Answer and Vote as Helpful
Free Windows Admin Tool Kit Click here and download it now
May 18th, 2012 10:49am
Hi Zach,
This works in straight forward SSRS but unfortunately not for my CRM reports.
Thanks for your help.
Maybe you can shed some light on my next question, it is on the same report:
http://social.technet.microsoft.com/Forums/en/sqlreportingservices/thread/0447e3f4-e1a5-4fed-81f4-4f2982498038
May 18th, 2012 11:05am


