Hide a report column in SSRS - sql-server-2008

I have a web SSRS (2008) report that has many columns (about 20). I would like to know if it is possible to allow the user to show/hide a particular column in the report by clicking some button or checkbox or the like? The purpose of this would be to allow the user to see the columns they want to see.

Right mouse click on the column and select "Visibility" property:
One of the options "Display can be toggled by this report item" - you can point to a dedicated, formatted textbox, clicking on which would show/hide column

Related

connected combo boxes in continuous form - the second combo doesn't show its value if dependent on first combo how could I fix that

I have a Continuous Form that has two combo boxes. If I don't link them together all values appear but if I link the two combo boxes to make one of them depend on other for easier choose from, the values never show in the second combo. I try to make code with if condition in vba to requery the combo values to show in all records but I couldn't. How could I do that? Thank you for all what you do
This technique is known as cascading combobox. A very common topic. Be aware that if combobox RowSource uses an alias (displays text when saving ID) the text will not be available for display in all records when the list is filtered. This is especially disconcerting for users of continuous/datasheet view form.
Could have code that only filters second combobox when it gets focus then restore the full list when loses focus. Users will still see data briefly disappear from other records and may find distracting at first but will learn to disregard.
However, a workaround to maintain display of text is to include the combobox RowSource lookup table in a query used as form RecordSource. Bind a textbox to the descriptive text field from lookup table. Set textbox as Locked Yes and TabStop No. In continuous view, can size and position textbox on top of combobox to obscure combobox text but still show drop arrow (a "hybrid" control). In datasheet view the textbox will not be superimposed but text will be displayed.
If controls are superimposed, users accustomed to clicking into combobox text frame and typing input will encounter aggravation as the textbox will likely be the control they click. Tabbing to the combobox or clicking drop arrow will cause combobox to get focus and display over the textbox.

How to create pop-up window containing filter options for a report

MS Access novice here with almost no VBA/SQL experience. I've created a database with tables, queries, forms, and reports that all function well together except a few select things I'm stuck on.
Purpose of changing to the below method: Currently, I have created three main report types, with different filter options for each report. AKA: there is a SEPARATE REPORT displaying each different filter option, even though the report contains the same root information. It'd be great to have one report that allows users to filter/group/sort multiple ways to streamline the reporting process.
I'd like to have a 'Filter' button on my Reports form that opens a pop-up window containing filter options via combo boxes. To clarify - the pop-up form has been created and I can easily add a 'Filter Options' button to the report form that opens the pop-up window.
The pop-up form has combo boxes with Control Sources related to the field names on the main table that the report pulls from, as well as buttons for 'Close', 'Apply Filters', and 'Clear Filters'.
What I need help with: getting the combo boxes to supply options as well as get the 'Apply Filters' button to actually work. The filter options need to pull from fields in one of the main tables, with no text entry allowed.
'Apply Filters' button needs to do the following:
Apply filters per combo box selections. Needs to be OK for Users to leave filters blank if they choose.
Gives User a preview of the report w/ applied filters
What you really want to do is close the report and re-open it using the Filter and Preview options. Look into DoCmd.OpenReport. You will have to convert your filter to an SQL language filter based on what he user selects but everything else is pretty straightforward.
So the way I would work this is build a criteria into the form query with a parameter surrounding your popup form's combo box
then in your form vba I'd write:
Private Sub Filter1_AfterUpdate()
DoCmd.Close acReport, "Rpt2_FWItemsDue_AllSubs"
DoCmd.OpenReport "Rpt2_FWItemsDue_AllSubs", A_PREVIEW
DoCmd.Maximize
End Sub
assuming the name of the control is "Filter1" and the name of your form is "Rpt2_FWItemsDue_AllSubs" and "Filter1" filters the "FW_SubName" in the report.

Show tables based on clicking a TextBox

I wanted to know if there is a possibility to have a Textbox on a report which says something like "SHOW TABLES". When clicked the tables in the report should show.
My report contains tables and Charts. I want to be able to show the charts but not the tables. I should be able to show the tables only when the user clicks on "SHOW TABLES"
It should not rerun the report once we click the TextBox.
It depends what you mean by "rerun the report".
You can set the ToggleItem property of the tables you want to hide to the name of your Show Tables textbox.
Set the initial visibilty of the tables to be hidden. Clicking the Show Tables textbox will show the tables. Clicking on the textbox will hide them again.
In my testing, the report will re-render, but it will not load its DataSets again. So there will be some processing to update the report appearance but it's more lightweight than reloading a report from scratch.
It may not fit your needs perfectly but might be worth investigating.
right click on the report "'tablix properties"
In Display can be toggled by this report item, from the drop-down box, type or select the name of a text box in the report in which to display a toggle image; for example, Textbox1.
In the following image, the table is configured to enable users to expand and collapse it. The display of the table is toggled by the Products Table text box.
5.To test the toggle, run the report and click the text box with the toggle image. The report display refreshes to show report items with their toggled visibility.

Changing the text in an SSRS report textbox based on the toggle state of a row group

Apparently this should have been simple. After lots of digging, I'm yet to find anything that works. I have a row group in my SSRS report whose visibility is toggled by a textbox. What I want is to have the text Show in the textbox when it's collapsed, and Hide when it's expanded.
But I can't find any property of the group that can give me its toggle state. I have found in a few forums that it's not possible. As a workaround, I've tried the InScope() function ( as suggested in http://forums.asp.net/t/1601570.aspx/1). But to no avail. Can anyone suggest anything?
I believe you are correct in stating that SSRS does not expose the ToggleState property for use in the report.
In these types of situations, I use report parameters to control the state of the report. For example, you could add a parameter named isGroupVisible to the report with a default value of 1 to represent visible. Set your group's visibility to that parameter, and set your text box value conditioned on the state of isGroupVisible. Then in the text box you set your actions to be go to a report, and set the report url to be the same report with the isGroupVisible = to the opposite of what it currently is.
You can decorate your text box all you want to give the users the indication that it can be pressed to toggle the state of the report.
Draw backs to this approach is that it isn't as snappy as the ajax calls SSRS does to expand visibility--it will post back to the server on each toggle press.
Advantages to this approach include much more flexibility in controlling the state of the report.

how to drilldown for some part of data in ssrs reports 2008

Hi I have to put drill down option for some part of Data.
My requirement is..I have 50 suppliers and i have to show top 10 suppliers as normal and for remaining 40 suppliers i have to put drill down option in ssrs report 2008
Please help.
In the Row Visibility properties of the row on which you've activated the +/- toggle (which is the window where you've activated the "Display can be toggled by ..." option), you can use an expression to show or hide the row. That means that you'll need to add something to your dataset so that you can decide whether or not a row should be shown by default.
You'll also need to add an expression to the InitialToggleState property of the textbox that's displaying the +/- icon. Otherwise it will become very confusing. The icon unfortunately does not automatically reflect the row's visibility.