Page tree
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

Create an Excel Report from an Existing RDL

This tutorial will help you design your first report in Excel using the OfficeWriter for Excel Designer from an existing report file (RDL) that was created in Visual Studio or Report Builder.

To follow this demonstration you need the AdventureWorks sample database which is an optional component in the Reporting Services installation. We will build a simple employee list and display some basic information about each employee.

Icon

Before you start, verify the following:

  1. Reporting Services is installed on a server you can access, working properly, and you have rights to publish and view reports.
  2. The AdventureWorks database (which ships with Reporting Services) is installed on the Reporting Services server.
  3. OfficeWriter Renderer is installed on the Reporting Services server.
  • The OfficeWriter Designer Client is installed on your local PC.
    For more information on installing and configuring OfficeWriter Reporting Services Integration, see Installation or contact your System Administrator.

OfficeWriter Designer Toolbar

The control center for creating reports with OfficeWriter is the OfficeWriter Designer toolbar. When you open Excel, you will see the toolbar directly underneath the Excel toolbar, above your worksheet.

If you do not see the toolbar:

  1. Open Excel's View menu and select >Toolbars > OfficeWriter.
    # Check OfficeWriter. If OfficeWriter is not listed, run the OfficeWriter client installer.

If your toolbar does not contain query-building buttons (Add Query, Edit Query, etc.), your registry settings have been set to disable MS Query. These buttons are not required for this tutorial, so you do not need to make any changes to your installation.

Opening a Report File

An a RDL file is an xml-based report definition file. We will open an RDL file created in Visual Studio. The file contains a database connection and a query. The query fields will appear in a drop-down list on the OfficeWriter toolbar. You will be able to insert these fields as merge fields (data placeholders) in the report template. You will not be able to create additional queries.

  1. Open Microsoft Excel and create a new file.
    # Click the Open Report button on the OfficeWriter toolbar.
    # If your report defintion file was saved on a local or network drive, navigate to the folder containing the file, select it, click Open, and continue to step 2. If your report defintion file was deployed to Reporting Services, click the Retrieve on the bottom right corner of the dialog box, and continue to step 3.
    !xlw_FirstfromRDL1.jpg!
    # In the Report Browser dialog box, type in your report server's URL or Domain name and click Refresh. This will load all the available report folders into the list box. Navigate to your report file, select it, and click Ok.
    !xlw_FirstfromRDL2.jpg!

Adding Fields to Your Report

For this demonstration we will use a report file created in Visual Studio containing the following query:

After opening your report in Excel with the OfficeWriter toolbar, you should find your query listed under the Select Query button.

  1. Click Select Query on the OfficeWriter toolbar and select your query from the drop-down list.
    !xlw_FirstfromRDL4.jpg!
    # Place your cursor in cell A2 cell and click inside it.
    # Click Insert Field on the OfficeWriter toolbar and select the ProductID field. Your template should now look like this:
    !xlw_FirstfromRDL6.jpg!
    # Place your cursor in cell B2 cell and click inside it.
    # Click Insert Field again and select the Namefield. Your template should now look like this:
    !xlw_FirstfromRDL7.jpg!
    # Place your cursor in cell C2 cell and click inside it.
    # Click Insert Field and select the ListPrice field.
    # Place your cursor in cell D2 cell and click inside it.
    # Click Insert Field and select the Days to Manufacture field.
    # In cell A1 type Product ID, in cell B1 type Product Name, in C1 type List Price, and in D1 type Days to Manufacture.

Your finished report template should look like this:

Publish and View Your Report

Before publishing the report on the Reporting Services server, we must save the template locally as an RDL file.

  1. From the OfficeWriter Designer toolbar select Save As.
    # Navigate to a local folder where you will store the template report file. This will be where you store your work file in case you want to edit it later, not a location on the Reporting Services server.
    # Save the template as an RDL file.
    # To publish the report, from the toolbar, select Publish.
    # From the Publish dialog box select the drop-down to display the Server or URL.
    # Choose the server on which Reporting Services is installed.
    # Click Refresh.
    # Select a folder for which you have publish rights and click Ok.
    # If your report published with no errors, you will receive a Publish Successful message dialog. Click Ok to continue.
    # To view the report, click View on the OfficeWriter Designer. The report viewer will open another Excel window with the report results. It should look like this:
    !cfxr_figure13.jpg!
    # Select Close Report View to return to your report template.

To verify that your report is actually running on Reporting Services:

  1. Open a browser and go to the Reporting Services Report Manager (usually installed at http://<server address>/Reports).
    # Navigate to where you published your report.
    # Select the report. Reporting Sevices will display the report but only show you the data set.
    # From the Select a format drop-down, choose Excel designed by OfficeWriter.
    # Click Export and - when prompted - Open . Excel will open and display your report the way you created it.

Samples

Download the .rdl file described in this tutorial.

  • No labels