# Oracle Business Intelligence Beans Sample

## Printing Crosstabs

### Overview

Printing Crosstabs demonstrates how to print a crosstab using the print facilities that are provided by BI Beans. `BIPrint` connects to Oracle OLAP (the source of the business data for the application) and to the BI Beans Catalog (where object definitions, like crosstabs and graphs, are saved).

`BIPrint` provides a menu with access to a simple connection dialog which prompts a user for security credentials. `BIPrint` then makes the two connections described above. After the connection is established, a new crosstab can be created using the New Crosstab file menu option. The Print dialog, the Page Setup dialog, or the Preview dialog can be invoked using the appropriate file menu options. Print dialog can also be invoked using the print button in the toolbar.

### Code Highlights

`BIPrint` uses the `PageSetupDialog`, `PrintDialog`, `PreviewDialog` classes to bring up the the 3 dialogs related to crosstab printing. Refer to the following 3 methods for more information.

`protected void showPageSetupDialog();
protected void showPrintDialog();
protected void showPreviewDialog();`

Copyright © 2004 Oracle Corporation. All Rights Reserved.