Data Regions , Containers, and Independent Report ItemsReport items (or presentation elements) in SSRS can be categorized as data regions (items that must be associated with data sets), containers (items that can contain other items), and independent report items. Some items can belong to more than one category. Independent report items are items other than data regions. Textbox, Image, Line, Rectangle, and Subreport are independent report items. Independent report items do not have to be associated with any data sources. Data regions function as a repetitive display of rows, groups of rows, or columns from a data set associated with a region. Table, Matrix, List, and Chart are data regions. In addition, data regions support grouping and sorting of displayed information. For more details of grouping and sorting, see Chapter 12, "Grouping, Sorting, and Aggregating Data, Working with Scope." All of the data regions, except Chart are also containers. Containers, as the name implies, can contain any reporting items, including containers and data regions. Table, Matrix, List, Rectangle, Report Body, Page Header, and Page Footer are containers. Items placed in a container become the container's children and the container becomes the parent. As a result, the Parent property of each child item is populated with the name of a container. All children move together with the container when the container is moved. When the container is deleted, all children are deleted. The container is fixed when the position of a report item within this container is fixed. For example, a Table is a fixed container because the position of each cell is fixed. Most, but not all, of the containers are also data regions. Thus, data regions can be nested within other data regions. Tip If you delete a container by mistake, you can easily undo this action using the Edit, Undo menu or by using the Ctrl+Z keyboard shortcut. For the shortcut to work properly, the focus of the action should be the ReportName.rdl[Design] (Data or Layout tabs) or ReportName.rdl[XML] window. From the perspective of RDL, the container has a <ReportItems> section, which is used to specify the beginning of a container for report items. For example, Table 11.1 shows the RDL of a Rectangle that contains a single Line. The graphical presentation of this RDL is shown in Figure 11.1. Table 11.1. Rectangle's RDL Explained
Figure 11.1. Line and Rectangle items. |