Working with PSR files

A PSR file is a special file with the extension PSR created by PowerBuilder, InfoMaker, or DataWindow Designer.

NoteWindows and PSR files When InfoMaker is installed, the PSR file type is registered with Windows.

A PSR file contains a report definition (source and object) as well as the data contained in the report when the PSR file was created.

Figure 6-1: PSR file

The graphic shows a rectangle labeled PSR file. Pointing to it are blocks that represent the report definition and retrieved data that make up the PSR file.

NoteAbout reports A report is the same as a nonupdatable DataWindow object. For more information, see “About reports”.

You can use a PSR file to save a complete report (report design and data). This can be especially important if you need to keep a snapshot of data taken against a database that changes frequently.

How PSR files are created

InfoMaker creates a PSR file when you:

Opening a PSR file

When you open a PSR file, InfoMaker displays the report in the Report painter. If InfoMaker is not already running, opening a PSR file automatically starts InfoMaker. You can open a PSR file in File Manager or Explorer, in a mail message, and using the File menu in the Report painter.

StepsTo open a PSR file in InfoMaker using Explorer or File Manager or from a mail message:

  1. Double-click the PSR file name.

    InfoMaker displays the report.

StepsTo open a PSR file from the menu bar in the Report painter:

  1. Select File>Open File from the menu bar.

    The Select a File Name dialog box displays.

  2. Select the PSR file you want. Change drives and directories if needed.

    The Report painter displays the report in the Design view.

  3. Select View>Preview to preview the report.

PSR files and retrieval

When you are previewing a PSR file, you see the data that was saved in the file when it was created. This is true until you explicitly retrieve data again using the Retrieve button or Rows>Retrieve from the menu bar.

If you attempt to retrieve data with a PSR file, you must be sure that you are properly connected to the right database. Otherwise, you will receive a database error message.

If you retrieve new data while previewing a PSR file, you cannot go back to the old data contained in the file. To go back to the old data, you must leave the PSR file without saving and then reopen the PSR file.

Mailing reports

While previewing in the Report painter, you can mail a report as a PSR file to an InfoMaker user who is using a MAPI-compliant mail system such as Microsoft Exchange. (MAPI stands for messaging application program interface and is one of the programming interfaces to mail systems.)

StepsTo mail a report:

  1. While previewing a report in the Report painter, select File>Send from the menu bar.

    If you are not logged on to your mail system, you will be prompted for your password.

  2. Enter your password and click OK.

    A form for mailing the report displays. InfoMaker creates and attaches the appropriate PSR file (which holds the report and data).

  3. Complete the form and send the message.

    InfoMaker mails the PSR file. The recipient can open the report by double-clicking it if InfoMaker is installed.