## Page Report Manager

All created page report files (.cls) are physically placed in the same directory where the catalog file resides. Due to this, you will not be able to get detailed information about a page report until it is opened in JReport Designer. For example, if you want to find a page report with a special condition, you will have to load each page report. For just a few page reports, this is not a problem. However, the case is different when there are many reports.

JReport provides you with a tool for managing page reports by means of adding them into folders with the Page Report Manager (the Reports tab of the Catalog Browser). You can build folder items in the manager, helping you to divide the page reports into different types at your disposal. Then, the reports can be added to the folder, and worked on just like processing files in a file system--add, open, delete, move, rename and search items. In all, the feature of report folder implemented in catalogs enables you to manage your page reports in a way that can better satisfy your requirements.

The following are some concepts used in the Page Report Manager:

- Folder Item: A container in which you can operate page report items or sub folder items.
- Report Item: This represents a page report. You can edit name, keywords and description properties of this item.

In the Page Report Manager, you can manage your page reports as follows:

### Adding an item

To add a folder item to the Page Report Manager:

1. In the Reports tab of the Catalog Browser, select a folder and right-click it.
2. Select Add Folder from the shortcut menu.

Now, a new folder will have been added as a sub node, and the default name for the folder is Folder1, Folder2.... However, you can rename the folder as required. To do this, right-click the folder item and select Rename from the shortcut menu, then type a new name in the name box, and then click outside the box (or just press Enter on the keyboard).

To add a report item to the Page Report Manager:

1. In the Reports tab of the Catalog Browser, right-click the folder to which you want to add the page report.
2. On the shortcut menu, click Add Page Report.
3. In the Choose Page Report dialog, select a page report. Here you can select multiple reports at a time. Then, click Open.

Now, the selected reports have been added to the specified folder. You can double-click any report item in the Page Report Manager to open the report. The default name of the report item is the file name of the report. However, you can give the item another name as you would with a folder item.

A report can be added to multiple folders in case you want to include it in multiple categories.

### Editing the properties of an item

Before you can edit the properties of any item, you should first make sure the "Forbid editing data object properties" option in the Catalog category of the Options dialog is unchecked (to access the Options dialog, click File > Options on the Designer menu bar, or the Options button on the Catalog Browser toolbar).

To edit the properties of an item:

1. Click the Expand button on the Catalog Browser toolbar, or right-click any item in the Reports tab and click Properties on the shortcut menu to display the Properties sheet.
2. Select the item the properties of which you want to edit, then edit its property values as required. After editing a value, press Enter on the keyboard to confirm the change.

The properties of a folder item are:

Property Name | Description
--- | ---
Description | Specifies the description of the folder. Data type: String
Name | Specifies the name of the folder. Data type: String

The properties of a report item are:

Property Name | Description
--- | ---
Author | Specifies the author of the report. Data type: String
Description | Specifies the description of the report. Data type: String
File Name | Specifies the name of the report. Data type: String
Keywords | Specifies the keywords of the report. Data type: String
Last Modified Time | Specifies the last time at which the report was modified. Data type: String
Last Print Time | Specifies the last time at which the report was printed. Data type: String
Last Run Time | Specifies the last time at which the report ran. Data type: String
Name | Specifies the display name of the report. Data type: String
Query Name | Specifies the query used by the report. Data type: String
Value Type | Specifies the type of the report. Data type: String

### Searching for a report or folder item

Wildcard searches for report name or folder name in the Page Report Manager are supported. To search a report or folder item, follow the steps below:

1. In the Reports tab of the Catalog Browser, select a folder item and right-click it.
2. Click Search on the shortcut menu to display the Search Reports dialog. See the dialog.

3. In the Find what text box, input the report or folder name, or report keywords you have specified for the Keywords property of the report in the Properties sheet, then select the corresponding search criteria from the By drop-down list, which can be by name, by keywords or by name or keywords.

   If you just input part of the report or folder name, or report keywords, use * to replace the other part of the name or keywords. For example, if you want to search for the report EmployeeInformation, you should input *Info* instead of info in the text box.

4. Specify what you want to find: a folder, a report or both.
5. Enter the search path in the Look in text box.
6. Specify whether to limit the search to text that exactly matches the case of the search text.
7. Specify whether to find the folder or report also in the subfolders of the search path.
8. Click the Search Now button to start searching. Matched results will be listed in the search result box.
9. If you want to start another search, click the New Search button and set the condition using the method described above.

### Exporting the report information to a table

You can export report information in the Page Report Manager to a table in a DBMS. The default name of the table is ReportsInfo. You can change the name as required. Each row of the table is a report description. To do this:

1. In the Reports tab of the Catalog Browser, select the root folder Reports and right-click it.
2. On the shortcut menu, click Export. The Get JDBC Connection Information dialog appears.
3. Fill in the required fields for connecting to the DBMS, and then click the OK button.
4. Give a name for the table, and then click OK in the Input dialog. The report information is added to the table in the DBMS.

You can then set up a JDBC connection in a catalog to connect with the DBMS and add the table to the catalog via the JDBC connection for use.

Note: If a table already exists, it will be replaced. So you must be sure that there are no duplicate names in the DBMS.

### Moving an item to another folder

Any items added to the Page Report Manager can be moved to another folder if required. To do this:

1. In the Reports tab of the Catalog Browser, select the item that you want to move and right-click it.
2. Click Move to on the shortcut menu.
3. The Move Reports dialog will then appear. All the available folders will be listed in the dialog.
4. Select the folder you want the item to be moved to, and click OK. The item will then be moved to that folder.

### Deleting items

By using the Catalog Browser, you can delete a report from the file system.

To delete a report or a folder or multiple items:

1. In the Reports tab of the Catalog Browser, select the report or the folder or the multiple items on the Reports tree, and then take either of the following ways:
   - Press the Delete key on the keyboard.
   - Click the Delete button on the toolbar of the Catalog Browser.
   - Right-click and select Delete from the shortcut menu.
2. A Warning message box is displayed. Check the option Also delete report files from file system if you want to remove them from your local directory permanently. Otherwise leave the option unchecked and only remove the items from the virtual tree.
3. Click Yes in the box. If a report is selected, the report will be deleted. If a folder is selected, the folder and all its contents will be removed.

If a report is deleted manually from the local file system, later when you open the Catalog Browser, you will see the node icon that represents the report is marked with a red cross. You can use the above method to remove the unused node.