Adding Rectangles and Lines (Report Builder 2.0)

You can use rectangles and lines to create visual effects within a report. You can set display properties on these report items from the Border section of the Home tab, and set other properties by using the Properties pane. You can add features like a background color or image, a tooltip, or a bookmark to a rectangle.

Adding a Container

A rectangle can be used as a container for other items. When you move the rectangle, the items that are contained within the rectangle move along with it. An item within the rectangle shows the name of the rectangle in its Parent property.

Note

A rectangle is only a container for items that you either create in the rectangle or drag into the rectangle. If you draw a rectangle around an item that already exists on the design surface, the rectangle will not act as its container. The rectangle will not be listed in the item's Parent property.

When using rectangles to contain report items, consider how the items will be affected as a whole during report rendering. Report items that contain repeated rows of data (for example, tables) will expand to accommodate the data that is returned by a query, and this affects the positioning of other items in the rectangle. A table will push items down if they are positioned below the data region. To anchor an item in place, you can place the report item inside of a rectangle that has an upper edge above the lower edge of the table. For more information, see Understanding Rendering Behaviors (Report Builder 2.0).

Adding a Report Border

You can add a border to a report by adding borders to the headers, footers, and report body themselves, without adding lines or rectangles. For more information, see How to: Add a Border to a Report (Report Builder 2.0).

Technical information

Rectangles and lines are not usually associated with data; however, you can attach them to a data region such as a table by using the RepeatWith property. For more information, search for "RepeatWith" in the Reporting Services documentation in SQL Server Books Online.