This documentation is archived and is not being maintained.

FindRenderSave Sample Windows Application

Updated: 5 December 2005

FindRenderSave is a sample Microsoft Windows application developed using Microsoft Visual Studio. The application is based on a real-world scenario, and it demonstrates how to develop a Windows application that uses the Report Server Web service. The sample uses the SOAP API to enable you to search for reports in the report server database, to review the report properties and to render the reports to various on-disk formats. This sample is not supported on Itanium-based operating systems.

The SQL Server samples are not installed automatically during setup. For instructions about how to install the samples, see Installing Samples.

ms160877.note(en-US,SQL.90).gifImportant:
Sample applications should not be connected to or used with your production SQL Server database or your report server without the permission of the system administrator.

You should be familiar with Microsoft Visual Studio and either Microsoft Visual C# or Microsoft Visual Basic, and your system must meet the following requirements to use the FindRenderSave sample:

  • Visual Studio 2005 or compatible development environment (for viewing the project files).
  • Microsoft .NET Framework version 2.0.
  • Reporting Services samples. You can choose to install the samples during SQL Server 2005 setup. For this release, when you choose to install samples, a separate installer is installed on your computer that you can launch to extract and install samples. You can run this installer from the Start menu in the Microsoft SQL Server 2005 program group.
  • A report server that you have permission to access on your network, if you plan to use the sample client application to view the contents of a report server and render reports. The sample assumes that you have SQL Server 2005 Reporting Services installed on your development computer.

This sample is located in the Application Samples\FindRenderSave Sample subdirectory of the Reporting Services samples directory.

For example:

C:\Program Files\Microsoft SQL Server\90\Samples\Reporting Services\Application Samples\FindRenderSave Sample

If you have not already created a strong name key file, generate the key file using the following instructions.

  1. Open a Microsoft Visual Studio 2005 command prompt. Click Start, point to All Programs, point to Microsoft .NET Framework SDK 2.0, and then click SDK Command Prompt.

    -- or --

    Open a Microsoft .NET Framework command prompt. Click Start, point to All Programs, point to Microsoft .NET Framework SDK 2.0, and then click SDK Command Prompt.

  2. Use the change directory command (CD) to change the current directory of the command prompt window to the folder where the samples are installed.
    ms160877.note(en-US,SQL.90).gifNote:
    To determine the folder where samples are located, click the Start button, point to All Programs, point to Microsoft SQL Server, point to Documentation and Tutorials, and then click Samples Directory. If the default installation location was used, the samples are located in <system_drive>:\Program Files\Microsoft SQL Server\100\Samples.
  3. At the command prompt, run the following command to generate the key file:

    sn -k SampleKey.snk

    ms160877.note(en-US,SQL.90).gifImportant:
    For more information about the strong-name key pair, see "Security Briefs: Strong Names and Security in the .NET Framework" in the .NET Development Center on MSDN.

  1. Open the solution (FindRenderSaveCS.sln or FindRenderSaveVB.sln).

  2. From the Debug menu, click Start Without Debugging.

  3. To exit the application, click Close.

  1. Use the Change Directory command (CD) to change to the \FindRenderSave directory.

  2. Type the following to build both the C# and Visual Basic versions of the sample:

    for /r %f in (*.sln) do C:\WINDOWS\Microsoft.NET\Framework\v2.0.40607\msbuild.exe "%f"
    
    ms160877.note(en-US,SQL.90).gifNote:
    The Windows system path and .NET Framework version number may differ on your system.

  3. In the application's \Bin\Debug directory, double-click FindRenderSave.exe to start the application.

  4. Click Close, to close the application.

After installing the FindRenderSave sample application, you can use the sample to search for reports, view report properties, and render reports to various on-disk formats. By default, the application attempts to connect to an instance of the Report Server Web service located on the same computer running FindRenderSave.

ms160877.note(en-US,SQL.90).gifImportant:
Sample applications should not be connected to or used with your production SQL Server database or your report server without the permission of the system administrator.

  1. Open FindRenderSave.sln in Visual Studio.

  2. On the Debug menu, click Start to run the sample application.

  3. Use the Search by list to search for reports by name, by description, or by both name and description.

  4. Enter the text that you want to use in your search in the Search string box. When you have finished entering your search string, click Search.

    A list of reports that match the search criteria appears in the Items found list.

  5. Click on any report in the Items found list to view the description and path properties.

  6. When a report is selected, you can render the report to one of four render formats: Excel, Image, Web archive (MHTML), or PDF. To select a render format, use the Render as list.

  7. To save the report, click Save Report.

    The Save As dialog box opens.

    ms160877.note(en-US,SQL.90).gifNote:
       FindRenderSave will not render or save reports requiring credentials or parameterized reports that do not have default values specified for all parameters.

  8. Choose a location and type a name for the report, and then click Save.

  9. To exit the application, click Close.

Release History

5 December 2005

Changed content:
  • Changed instructions for generating a key file, including the name and location of the key file.
Show: