<< Click to Display Table of Contents >>

 

You can hide a specific table cell conditionally, for instance, based on a report parameter value.

Right-click the Parameters section in the Field List and select Add Parameter.

eurd-win-create-parameter-to-hide-table-cells

In the invoked Add New Parameter dialog, specify the parameter's name and description for Print Preview, and set the type to Boolean.

eurd-win-parameter-settings-to-hide-table-cells

Specify an expression for the cell's Visible property to define a logical condition for displaying or hiding this cell.

The image below demonstrates how to provide the visibility expression for the cell bound to the CategoryID field. For a report to display correctly, you should specify the same expression for the cell that displays the field caption in the Page Header.

eurd-win-hide-table-cell-using-expression

The Process Hidden Cell Mode property allows you to define how to distribute the remaining space between the table's visible cells.

eurd-win-table-process-hidden-cell-mode

The image below illustrates how the original table looks like:

eurd-win-table-hidden-cell-mode-initial-layout

The following modes are available to process hidden cells:

StretchPreviousCell - A cell to the left of the hidden cell is stretched to occupy the available space. If the hidden cell is the first in the row, the next cell is stretched.

eurd-win-table-hidden-cell-mode-stretch-previous-cell

StretchNextCell - A cell to the right of the hidden cell is stretched to occupy the available space. If the hidden cell is the last in the row, the previous cell is stretched.

eurd-win-table-hidden-cell-mode-stretch-next-cell

ResizeCellsEqually - All visible cells are resized to divide the space that a hidden cell reserved equally.

eurd-win-table-hidden-cell-mode-resize-cells-equally

ResizeCellsProportionally - All visible cells are resized to proportionally divide the space that a hidden cell reserved based on their weights in the whole table width.

eurd-win-table-hidden-cell-mode-resize-cells-proportionally

DecreaseTableWidth - The table width is decreased, and visible cells are shifted to a hidden cell's location without changing their size.

eurd-win-table-hidden-cell-mode-descrease-table-width

LeaveEmptySpace (the default mode) - A space remains at a hidden cell's location, and other cells are not affected.

eurd-win-table-hidden-cell-mode-leave-empty-space