|By Terry Dykstra||
|June 1, 2004 12:00 AM EDT||
Many PowerBuilder developers know that InfoMaker can be used as a reporting tool. Out of the box, InfoMaker seems fairly restricted as to which type of applications can be developed. However, few people realize that InfoMaker also allows end users to create forms, the equivalent of PowerBuilder windows. Add the pipeline and database painter and you can see that end users have a very powerful tool for managing their data.
We'll look at exactly what can be done with InfoMaker. First, we'll take a high-level overview of InfoMaker's capabilities - particularly as compared to PowerBuilder's. Second, we'll look at the two primary methods available to PowerBuilder developers to add functionality to applications developed with InfoMaker:
- Custom form styles
- Customizing the imstyle9.pbl
The InfoMaker Environment
InfoMaker is first and foremost a report writer built around the DataWindow. It also includes the query and library painters familiar to PowerBuilder developers. If the "write" option is selected during the install, it will install the pipeline and database painters. The "write" option also installs one of the features unique to InfoMaker - the so-called form painter - that is basically a customized window painter with a built-in wizard.
Another feature unique to InfoMaker is the Query Governor (see Figure 1), which allows an administrator to put restrictions on the types and sizes of queries the InfoMaker end user can generate. For example, it allows the administrator to limit the number of rows retrieved or the number of tables that can be joined in a select statement. However, the administrator should realize that the end user could bypass the "Data Selection Options" by converting the SQL statement to syntax. In addition, administrators may choose to deploy InfoMaker so that it uses a shared IM.INI file on the network, which will allow them to restrict certain features, such as the use of built-in forms.
InfoMaker also differs from PowerBuilder in that it does not use the concept of workspaces that was introduced with PowerBuilder 8. The GUI is essentially the same as that of PowerBuilder 7. InfoMaker also supports the same set of native, OLEDB, ODBC, and JDBC database interfaces as PB Enterprise. Unlike PowerBuilder, however, the end user can only be connected to one database at a time.
The first difference a PowerBuilder user will notice when using InfoMaker is the limited list of items visible in the library painter. The data pipeline, report, query, and form objects are the only objects available. As mentioned before, InfoMaker does not support the workspace/target concept. Instead, InfoMaker users select the "application" they are going to work on by setting the "working library." To set the working library, the end users must right-click on the pbl and choose "Set as working library." Another option on the right-click popup menu is "Print Directory," which will generate a quick report of all the objects within the pbl (including those not visible in the library painter).
The Library Search path is also set differently in InfoMaker than in PowerBuilder. In InfoMaker the Library List is used. Unlike PowerBuilder, it has two separate tabs:
- Style Tab: Here any pbl(s) containing custom form styles and/or global functions are added. Custom form styles are described in more detail later in the article. While the pbls can be added here, the custom form styles and global functions must be created using PowerBuilder.
- Query Tab: Here any pbl(s) containing prebuilt query objects are added, which can later be used when building reports or forms.
The InfoMaker report painter has many of the same basic features as the PowerBuilder DataWindow painter. The major exception is that the InfoMaker report painter does not allow end users to provide their reports with an update capability. As a result, it also does not allow the end user to set the tab order for columns in the report. This becomes a problem when trying to modify DataWindows used in forms. In the section on "Custom Form Styles" we will see how we can work around this. Also note that InfoMaker Reports always display in Print Preview mode.
Just as with PowerBuilder, InfoMaker allows you to call global functions from within a report. However, you must use PowerBuilder to create those global functions. To use global functions in your reports, first add the pbl containing these functions to the Library List's Style Tab. Note that an InfoMaker user cannot see the global functions, therefore, it's a good idea to provide a window that allows him or her to browse these functions.
Pipeline and Database Painter
These painters are exactly the same as PowerBuilder's. Database profiles for the database painter can be shared by pointing to a shared ini file on the network.
Forms allow you to create basic data entry screens. There are four predefined form styles:
- Master/detail one-to-many
- Master/detail many-to-one
Some companies prefer to disable the use of the default forms, and instead rely on their in-house developed custom form styles. In the shared initialization profile (accessed through Tools, System Options), the administrator can add the following line under the [Window] section to disable default forms:
ShowStandardStyles = 0
Setting this parameter in the local im.ini file has no effect. When end users build forms, they can immediately run these in the development environment. InfoMaker does not require an application object like PowerBuilder does to run forms.
To create applications InfoMaker uses a hidden "default" application object and a hidden "default" project object. These are automatically generated when the user selects "Design, Create Executable" from within InfoMaker. When doing so, the user can choose to reuse the settings from the most recently created executable or start with new settings. If the first option is chosen, InfoMaker will examine the last built executable and extract from the m_pbstyle_frame menu all the objects that were included. A wizard steps the user through the whole build process, allowing them to select reports, pipelines, and forms to be included in the final executable. Desired buttons can be assigned to individual objects and reports (like those used for dropdown DataWindows) can be hidden. With InfoMaker the application is always generated as a single EXE file - there is no concept of PBD or PBR files within InfoMaker.
Together with the executable a matching initialization file is generated, i.e., myreports.ini goes with myreports.exe. The ini file always contains the [database] and [dbms_profiles] sections that have SQLCA connection parameters based on the current database profile. Optionally you can add a [pipe] and/or a [about] section (see Table 1). The [pipe] section allows a user to change the behavior of pipeline objects. The [about] section allows you to set information that will show in the "Help, About" menu of the executable.
When creating an executable you can now provide Product and File version information to executables. The version number is in the form 0,0,0,0. Besides the version number you can also provide a description. The Microsoft Installer can read the version information to determine whether to update an executable.
- SAP Withdraws PowerBuilder 15 and Releases 12.6 Instead!
- Free ASE & IQ Software
- AIRMAN on the Amazon Cloud via APPEON
- Appeon 2015 beta - New Release Highlights
- FacialNetwork, Global Leader In Cloud-Based Facial Recognition, Names Satya Yenigalla As Chief Operating Officer
- Five Best Practices to Help DBAs Simplify the Complexity of Managing Virtualized Databases
- SIOS Webinar to Address Optimizing Cost Savings and High Availability Protection for Postgres with EnterpriseDB and SIOS Clustering Software
- Where Are RIA Technologies Headed in 2008?
- PowerBuilder History - How Did It Evolve?
- Creation and Consumption of Web Services with PowerBuilder
- Cloud People: A Who's Who of Cloud Computing
- DDDW Tips and Tricks
- Working with SOA & Web Services in PowerBuilder
- Cloud Expo 2011 East To Attract 10,000 Delegates and 200 Exhibitors
- Dynamically Creating DataWindow Objects
- OLE - Extending the Capabilities of PowerBuilder
- DataWindow.NET How To: Data Entry Form
- Custom Common Dialogs Using SetWindowsHookEx
- Cloud Expo and The End of Tech Recession
- Solutions for Optimizing ASP.NET Applications
- Dynamic SQL
- Office 2003 Toolbar: A New Look For Your Old PowerBuilder App