CHAPTER 9 RENDERING REPORTS FROM .NET APPLICATIONS
Designing the Report
To design the report, follow these steps:
- To add a report to the project, right-click the project name—SSRS Viewer
RVC—in the Solution Explorer. - On the shortcut menu, select Add ➤ New Item. This opens the Add New Item
dialog box. - Select the Reporting section on the list to the left, then click the Report icon,
enter EmployeePay.rdlc for the file name, and then click Add. This launches
the Report Designer functionality in Visual Studio. The .rdlc extension signifies
that it is a report for client or local rendering. - Make sure the report is selected. Open the Toolbox. From the Toolbox, drag a
Table report item onto the report. - You should now be presented with the Dataset Properties window. From this
window, select the Employees option in the Data Source drop down list. You
will see the fields from this data source populated in the Fields data grid to the
right. Name this dataset Employees_EmployeePay and click OK. - You should now see the table in your report designer. In the Data row of the
first column, click the field icon in the top right hand corner to select a field. In
the first column select the Employee ID field. - Perform this task again for the second and third columns. Choose StartDate
and Amount for the second and third column, respectively. - Add a textbox to the top of the report and use the text “Employee Pay Report”
for the value.
You should now have a report that looks like Figure 9-5.