Search the Wiki

Viewing 246 to 280 of 409 items

Report Explorer

The Report Explorer component allows you to deploy a Windows Explorer interface that your end-users can use to organize their reports. The Report Explorer handles all operations via datapipelines; therefore, the folder structure and all of items within it can be saved to database tables. This interface presents a minimal learning curve as most users  Full Article…

0

Report Designer

The Designer is a non-visual component that acts as a ‘wrapper’ around the report designer window displayed in the end-user reporting solution. By setting the various properties and events of the designer component, you customize the content and behavior of the report designer. The most commonly used properties of the designer component are listed below:  Full Article…

0

Putting It All Together

In order to create the most sophisticated and complete end-user reporting solution possible using ReportBuilder, we need to connect and configure all of the components available in ReportBuilder Professional. The screenshot shows the configuration of a full-featured end-user reporting solution (the colored shapes and labels have been added for informational purposes only). A completed version  Full Article…

0

Licensing

ReportBuilder Professional and Enterprise Editions include the ability to build end-user reporting solutions that are royalty-free. The End-user reporting solution must be a part of a larger application and access a single database. For example, you cannot build a general purpose query or reporting tool and distribute that royalty-free. The license prohibits this type of  Full Article…

0

Data Dictionary Builder

The Data Dictionary Builder is an editor for the DataDictionary component. It is designed to generate and maintain the DataDictionary information used by the Data workspace. To access the DataDictionary Builder, configure the DataDictionary.BuilderSettings to connect to your database and then double-click on the DataDictionary component. The following options are provided:  Option Description   Generate Automatically  Full Article…

0

Data Dictionary

The data dictionary is a non-visual component designed to provide the data workspace with the capability to replace the table names and field names retrieved from the database with more readable aliases that you provide. The most commonly used properties of the data dictionary are described below:  Property Description   FieldFieldNames The names of the fields  Full Article…

0

Tech Tip…Control UI Theme

Tech Tip: Control UI Theme ReportBuilder 10 introduced support for Themes (Skins). There are a couple of options for specifying which theme is used. Report DesignerFrom the Report Designer select View | Themes from the main menu and then select the theme that you would like to use. The specified theme will be stored in  Full Article…

0

How To…Show the Designer in Panel

Question “How can I show/embed the Designer in a Panel?” Solution The following example uses the Designer.ShowInPanel method to display the display the designer within a panel and optionally move the menu bar to the parent form. Download: ShowDesignerInPanel.zip Sample Delphi code: procedure TForm1.btnShowDesignerPanelClick(Sender: TObject); begin ppDesigner1.ShowInPanel(Panel1); end; procedure TForm1.btnShowDesignerInPanelClick(Sender: TObject); begin // move the  Full Article…

0

How To…Select a Default Folder in the ReportExplorer

Question “How can I select a default report explorer folder for my end-users to save their reports?” Solution The following example uses the Report.Template.OnNew and OnLoadEnd events to set the default folder for the user to save reports. Download: ReportExplorerSelectDefaultFolder.zip Sample Delphi code: procedure TmyEndUserSolution.ehReport_New(Sender: TObject); begin ppReportExplorer1.CurrentFolderId := GetFolderId('Customers'); end; procedure TmyEndUserSolution.ehReport_LoadEnd(Sender: TObject); begin  Full Article…

0

How To…Refresh Data Tree

Question “How can I refresh the Designer Data Tree via code?” Solution The following example shows how to refresh the Data Tree window. Download: RefreshDataTreeInCode.zip Sample Delphi code: uses ppEndUsr, ppToolWnTBX, ppDesignLayoutManager, ppDesignToolManagerTBX; procedure TForm1.ppDesigner1Show(Sender: TObject); var lLayoutManager: TppDesignLayoutManager; lToolManager: TppDesignToolManager; lDataTree: TppDataTreeWindow; begin lLayoutManager := ppDesigner1.Form.LayoutManager; // get the ToolManager lToolManager := lLayoutManager.ToolManager; //  Full Article…

0

How To…Launch the Report Wizard in Code

Question “How can I launch the Report wizard directly in code?” Solution a. Simplest solution is to use the Designer uses ppWizard; begin // note: this example works with RB 10 and later myDesigner.Form.LayoutManager.DocumentController.New(ppDefaultReportWizard); end; b. It is also possible to launch the report wizard without the Designer Start by manually creating a TppReportWizard object and implementing the  Full Article…

0

How To…Launch the Label Wizard in Code

Question “How do I launch the label wizard directly in code without having to go through the designer?” Solution Do this by manually creating a TppLabelTemplateWizard object and executing it.  Then it is up to you to manually create the report in code based on the user selections. Download: LaunchLabelWizardInCode.zip Sample Delphi code: uses ppLabWiz;  Full Article…

0

How To…Implement Custom Open/Save events

Question “How can I implement custom processing when reports are loaded/saved?” Solution The following example shows how to implement the Designer OnOpenDoc and OnSaveDoc events to either override or augment the built-in save/load logic. When the OnCustomOpenDoc, OnCustomSaveDoc events are assigned, the report designer will not save or load any reports – it will instead  Full Article…

0

How To…Hide Object Inspector Properties

Question “How can I hide some of the object inspector properties from my end-users?” Solution The following example shows how to use the PropertyCategoryManager to hide the EmailSettings property. Download:  DesignerHideObjectInspectorProperties.zip Sample Delphi code uses ppInspector; procedure TForm1.Button2Click(Sender: TObject); var lPropertyCategory: TppPropertyCategory; liIndex: Integer; begin // remove EmailSettings from the User Interface category lPropertyCategory :=  Full Article…

0

How To…Hide Notebook Tab

Question “How can I control the visibility of the Notebook tabs?” Solution The following example shows how to use the Designer.Notebook.SetTabsVisible method to hide the Preview tab. Download: DesignerHideNotebookTab.zip Sample Delphi code: procedure TForm1.Button1Click(Sender: TObject); var liPreviewTab: Integer; begin liPreviewTab := ppDesigner1.Notebook.PageCount-1; ppDesigner1.Notebook.SetTabVisible(liPreviewTab, False); ppDesigner1.ShowModal; end;  

0

How To…Hide DADE Menu Items

Question “How do I hide some or all of the menu items for the Data Tab?” Solution Check to see that the user has the data tab active in the TabChanged event and typecast the Designer.Menu.Items property as a Data menu object to access the menu items. Download: HideDataMenuItems.zip Sample Delphi code: procedure TForm1.ppDesigner1TabChanged(Sender: TObject);  Full Article…

0

How To…Default Settings for Reports

Question “How can I implement default report settings for new reports created by end-users? And for existing reports?” Solution The following example uses the Report.Template OnNew and OnLoadEnd events to implement default report properties. Download: DesignerInitializeReportProperties.zip Sample Delphi code: procedure TForm1.Button1Click(Sender: TObject); begin // initialize report properties InitializeReport(ppReport1); // assign template event-handlers ppReport1.Template.OnNew := ehTemplate_New;  Full Article…

0

How To…Customize Designer Menu and Toolbars

Question “How can I customize the menu and toolbars?” Solution The following example shows how to acess the menus and toolbars to add/remove items, hide toolbars, and assign custom event-handlers. Download: DesignerCustomizeMenusAndToolbars.zip Sample Delphi code: uses ppTBX, ppToolbarTBX, ppDesignLayoutManager, ppDesignLayoutMenu, ppDesignToolManagerTBX, ppDesignToolbarsTBX, ppDesignToolActions, ActnList; {****************************************************************************** Example: hide File | Print menu item ******************************************************************************} procedure TForm1.btnHideFilePrintClick(Sender:  Full Article…

0

How To…Add Custom Tool Window

Question “How can I add a custom tool window to the Designer?” Solution The example shows how to create a custom tool window and register it with the Design tools. Download: DesignerAddToolWindow.zip Sample Delphi code: uses ppDesignToolWindow, ppToolbarTBX; type // descend from TppDesignToolWindow TmyDesignToolWindow = class(TppDesignToolWindow) public constructor Create(Owner: TComponent); override; end; implementation constructor TmyDesignToolWindow.Create(Owner:  Full Article…

0

Using Template Events

The Report.Template object has several events that can be used for customizing what happens when a report is loaded or saved: – OnLoadStart – OnLoadEnd – OnNew – OnSaveStart – OnSaveEnd The OnLoadEnd and OnNew events are often used to perform actions related to report and data initialization. The OnSaveEnd event is often used to  Full Article…

0

How To…Troubleshoot Lost Event Handlers

Question “How do I troubleshoot lost event handlers?” Solution Let’s assume you have created a report in Delphi and assign an event handlers to the OnPreviewFormCreate event of the report.  The event is generated by Delphi as: Sample Delphi code: procedure TForm1.ppReport1PreviewFormCreate(Sender: TObject); You then save the report to an RTM file ‘Report1.RTM.’  The events  Full Article…

0

How To…Troubleshoot Error Loading Report From Database

Question “How do I troubleshoot error loading report from database?” Solution Check the BDE configuration setting for BlobSize. This value defines the maximum size for a blob. The default value is 32, which is too small for most reports. Increase the size to 1024 or 2048 to accommodate your largest report definitions. If you are using  Full Article…

0

How To…Store Information With My Report Template

Question “How do I store descriptive information with my report template?” Solution If you are storing the templates to a database, then you can use the Report.Template.OnSaveEnd and OnLoadEnd events to store and load the custom information to appropriate data fields for the record. (This is the technique used by the ReportExplorer.) If you are  Full Article…

0

How To…Reassign Event Handlers

Question “How do I reassign event handlers?” Solution Whenever you save a template to an .rtm file, all of the published properties of the Report are saved. This includes all Properties and Events that are visible in the Object Inspector. For the events, the ‘name’ of the event-handler procedure is saved. When you load an  Full Article…

0

How To…Programmatically Load Reports Saved Using the Report Explorer

Question “How do I programmatically load reports that were saved using the Report Explorer ?” Solution The ReportExplorer has a run-time interface you can use to load reports using the ReportExplorer.LoadReport method. You can use this method without actually ‘showing’ the report explorer form. (See the online help topic for TppReportExplorer.) If you want use Report.Template.LoadFromDatabase,  Full Article…

0

How To…Load Report Templates from a Database

Question “How do I load report templates from a database?” Solution Reports can be saved to a database at design-time or run-time. First, create a database table that contains a BLOB field for storing the templates and a string field for storing the name of the templates:For this example let’s create a table called reports  Full Article…

0

How To…Implement Event-Handlers for Report Templates

Question “How do I implement event-handlers for report templates?” Solution The best solution is to code the calculations and event-handlers in RAP, the run-time Pascal coding evironment included with ReportBuilder Enterprise. RAP enables the event-handler code to be saved in the .rtm templates as part of the report definition. If you use Delphi event-handlers as  Full Article…

0

How To…Display Report Open/Save dialogs

Question “How do I displaying report Open/Save dialogs?” Solution The Report.Template object has several events that can be used for customizing what happens when a report is loaded or saved: OnLoadStart OnLoadEnd OnNew OnSaveStart OnSaveEnd The OnLoadEnd and OnNew events are often used to perform actions related to report and data initialization. The OnSaveEnd event  Full Article…

0

How To…Customize Open/Save To File Dialogs

Question “How do I customize the Open/Save To File dialogs?” Solution The Report.Template property has an OnCreateDialog event. The public event is defined as: property OnCreateDialog: TppDialogEvent read FOnCreateDialog write FOnCreateDialog; And the TppDialogEvent type is defined as: TppDialogEvent = procedure(Sender: TObject; aDialog: TObject) of object; You can customize the TOpenDialog and TSaveDialog properties by  Full Article…

0

How To…Change Default Template Extension

Question “How do I change the default template extension in Open/Save dialogs?” Solution Use the following code to change the default file extensions which will be used when the open and save dialogs are created to load or save a template. Sample Delphi code: ppReport1.Template.FileExtension := '.mfe'; ppReport1.Template.FileFilter := 'My Format Extension (*.mfe)|*.MFE'; Substitute the  Full Article…

0

Multi-Page Spanning

Question: “I have more data than will fit on one page width. How can I span multiple pages?” Solution: If you are creating a crosstab report, this is done automatically. However, for other types of reports, this must be done manually. Basically, we will create one section-style subreport for each page width we need to cover.  Full Article…

0

How To…PageBreak when X Space Left

Question “How can I force a page break when less than X amount of space left?” Solution For simple layouts, use the DetailBand.PrintCount property to limit the number of times a static height detail band prints on each page. For layouts with dynamic height detail, this example shows how to use the DetailBand BeforePrint event  Full Article…

0

How To…PageBreak On a DataValue

Question “How can I force a page break on specific data values?” Solution This example conditionally controls pagination by using a PageBreak component in the detail band andconditionally toggling the PageBreak.Visible property. Download: PageBreakDataValueRAP.zip Sample RAP code: procedure DBText1OnPrint; begin { force a page break } if orders['OrderNo'] = 1010 then PageBreak1.Visible := True else  Full Article…

0

How To…Collate Subreport Pages

Question “How can I can collate the pages of my subreport?” I have two subreports and would like for the pages to alternate subreport1 page 1, subreport2 page 1, subreport1 page 2, subreport2 page 2,.. Solution This example generate the pages to cache, then re-orders the page cache, prior to preview. Download: CollateSubReportPages.zip Sample Delphi  Full Article…

0

How To… Print Two Copies Per Page

Question “How do I print two copies of the same report on a single page?” Solution Use Fixed style subreports sized to exactly half the paper height inside the detail band of the report. If you would like any overflow to move to the next page, be sure to set the TraverseAllData property of the  Full Article…

0