Power Objects Frequently Asked Questions
Q: What is Oracle Power Objects?
A: Oracle Power Objects is an object-oriented development tool for building client/server database applications quickly and easily. It is a small footprint product ideally suited to creating applications for laptops and desktops in a client/server workgroup environment. An integral component of the Oracle Workgroup/2000 product family, Oracle Power Objects also offers powerful cross-platform development capabilities; you can build applications on the Macintosh and move them to Microsoft Windows and vice versa.
Q: What is the most current version of Oracle Power Objects?
A: The most current version of Oracle Power Objects is version 1.0.16, the final patch to v1.0, the first production release.
Q: What do I need to run Oracle Power Objects?
A: Oracle Power Objects will run on the following*:
*Note: For a complete list of hardware and software requirements for Oracle Power Objects, please see the Web page on technical requirements.
Q: What other platforms will be supported?
A: PowerMac native and Windows95/WindowsNT native versions of OPO are both planned for release in August '96.
Q: When will there be a new version of OPO and what will it include?
A: Version 2.0 of OPO is scheduled for release in August '96. This new release will include a heirarchical Object Browser, BASIC Code Editor, Grid Control, ODBC support and a language reference book covering SQL and BASIC.
Q: What other native-language versions of OPO are available?
A: OPO is now available in English, Japanese (Kanji) and Korean (Hangul). A German version for Windows will be available shortly.
Q: How does Oracle Power Objects fit into Oracle Workgroup/2000?
A: Workgroup/2000 is a comprehensive product line providing all the components a developer needs to build complete client/server applications. The database products, Personal Oracle7 for Windows and the Oracle7 Workgroup Server, provide the data storage. Oracle Power Objects is the development tool to build applications which present that data to the user. Oracle Objects for OLE opens up the database, allowing any OLE-compliant application to read and write from it. Oracle Mobile Agents is an API called from C that allows developers to build applications that send and receive messages over a wireless network; it can be called from Oracle Power Objects via an included DLL routine.
Q: What is the difference between the Personal Edition and the Client/Server Edition of Oracle Power Objects?
A: The Personal Edition is licensed for connectivity to Blaze (the included local database) and Personal Oracle7 (currently only on Windows). The Client/Server Edition is licensed for connectivity to any Oracle7 database, Sybase SQL Server or Microsoft SQL Server, in addition to Blaze.
Q: What is the relationship between Oracle Lite and the "Blaze" database in Power Objects?
A: Blaze is a single-user relational SQL database built into Oracle Power Objects. It offers ease-of-use and a small footprint for standalone users. Oracle Lite was developed independently, with very similar goals. To maximize compatibility between Oracle products, Oracle Lite will be merged into a future release of Oracle Power Objects in place of Blaze. All Power Objects applications and data will migrate automatically, ensuring a stable and easy transition path for current and future Oracle Power Objects customers. Oracle Lite will be available on all Power Objects platforms (Windows, Macintosh, and OS/2).
Q: Is the Trial Edition of OPO the Personal or Client/Server Edition?
A: It is the full-featured Client/Server Edition.
Q: What does Oracle Power Objects cost?
A: OPO list prices are: $1,995.00 for the Client/Server Edition* (Mac or Windows) $ 395.00 for the Personal Edition** (Mac or Windows) * Note: A $1,495 pricing promotion is in effect for the Client/Server Edition (available through March '96). ** Note: A $99 competitive upgrade is available for users of Visual Basic, Access, FoxPro, Paradox or Fourth Dimension (available through March '96).
Q: Is there a user limit or licensing fee for finished applications?
A: No, OPO is licensed per developer seat; developers can deploy unlimited runtimes free of royalty charges. This includes applications working against a Blaze database, in which case the database and the application files are both deployed.
Q: Why would I want to upgrade from Visual Basic to OPO for $99?
A: OPO leverages existing VB expertise by implementing the BASIC scripting language, a familiar developer environment, and support for OLE 2.0 and OCXes, but also adds the following features: o superior database integration (including drag-and-drop binding & data-aware controls) o object-orientation for re-using visual classes o cross-platform support for Macintosh
Q: How does one migrate from Microsoft Visual Basic to Oracle Power Objects?
A: The scripting language for Oracle Power Objects uses the same syntax as Visual Basic, making the switch easy for those familiar with VB. OPO also supports Windows standards such as OLE 2.0 and OCX custom controls. Oracle is working with third-party vendors to develop migration tools to eventually allow developers to convert their existing VB applications to Power Objects.
Q: How do I know if I should be using Oracle Power Objects or Developer/2000?
A: Oracle Power Objects is for indiviual and workgroup developers who want to build small to medium sized applications. Developer/2000 is Oracle's flagship development environment for building enterprise-wide applications. In order to determine when to use which tool, you should ask yourself the following questions:
Q: What can OPO Client/Server Edition connect to?
A: Currently the supported database servers are Oracle7, Sybase SQL Server 4.2 & System10, and Microsoft SQL Server 4.2. An ODBC driver will be included with the next release. This will enable easy drag-and-drop migration of data from foreign formats to or from Oracle7 via Power Objects.
Q: Does the Client/Server Edition of OPO work with Oracle6 databases?
A: No, OPO only supports Oracle7 databases; Oracle6 databases must be upgraded or accessed with the appropriate ODBC drivers.
Q: What do I need to connect to an Oracle7 database?
A: You must have the Client/Server (or Trial) Edition of Oracle Power Objects. Also, Oracle's SQL*Net must be installed in order to connect to an Oracle7 server. Please refer to the technical requirements page on the Web or the documentation for the correct version information on SQL*Net software. You can connect to Personal Oracle7 with the Personal Edition.
Q: What do I need to connect to a SQL Server (or System 10,11) database?
A: You must have the Client/Server (or Trial) Edition of Oracle Power Objects. Also, Sybase's OpenClient/C drivers (version 10.01 or higher for Windows) must be installed.
Q: What is the built-in database functionality of Oracle Power Objects?
A: Oracle Power Objects automates most database interaction necessary for workgroup applications: o default field-to-column and form-to-table linking o automatic sequence number generation o automatic BLOB binding to bitmap frames o default master-detail coordination o data integrity requirements (primary keys, foreign keys, etc.) o multi-user concurrency control (row locking) o all SQL statements: queries, inserts, updates, deletes o full cursor control, forward/backward scrolling o graphical table creation and modification
Q: Does Oracle Power Objects work with ODBC drivers?
A: ODBC driver support will be included in v2.0, scheduled for release in April '96.
Q: What are the features of the included local database?
A: Blaze is a full-featured, small-footprint SQL database engine that is included with both the Client/Server and Personal Editions of Oracle Power Objects v1.0. It is a fast and easy way to build small database applications without requiring a connection to an installed database server. This means that Oracle Power Objects is up and running out of the box. Tables and data in the local database can be uploaded to a database server by dragging and dropping the table icon(s) from the local session window to the session window of the database server. Applications can then be pointed at the new server by changing a single property. Version 2.0 will incorporate Oracle Lite, Oracle's corporate-wide standard local database. Oracle Lite is ODBC-accessible, completely compatible with Oracle7, and requires less than 1 MB of memory. (An automated tool will be provided for migrating data from Blaze to Oracle Lite.)
Q: How can I import data from a flat file?
A: Please read the technical bulletin on writing an application to import ascii text files.
Q: How can I migrate data between databases?
A: Migrating data between databases is a drag-and-drop feature of OPO. Simply create and connect a session to one database, do the same for the other database, and then drag and drop the table icon(s) from the local session window to the session window of the database server.
Q: What is the object structure/heirarchy of Oracle Power Objects?
A: There are three categories of objects in Oracle Power Objects: o Applications - include classes, forms and reports designed by the developer specifically for an application. o Libraries - include classes designed by the developer and imported bitmaps which are used in several applications. o Sessions - represent database connections; include tables, views, indexes, sequences, and synonyms.
Q: How do I take advantage of the object orientation of OPO?
A: OPO allows developers to create visual re-usable classes and store them in Applications or Libraries. It is possible to create an unlimited number of instances of each class. Inheritance is enforced on a property-by-property basis, allowing customization of class instances.
Q: How would you access flat files from an Oracle Power Objects application?
A: The best solution would be to load the files into an Oracle7 database, which would give you much more power overall. This can be accomplished using Oracle's SQL*Loader or building an application to move the data from a flat file to a database.
Q: How can you access tables you do not "own" in Oracle Power Objects?
A: You will need to create a synonym for those tables; you must own the synonym.
Q: How can I make two forms share the same recordset?
A: In Oracle Power Objects, there are many occasions when you want two forms (or other bindable containers) to share the same local copy of records queried from the database. For example, if you want to create a browser form to give users the ability to quickly scan through records, you want to move the pointer in the recordset to whatever record the user selects in the browser. In this and other cases, you can establish a shared recordset between the forms through the RecordSource property, using the following syntax: =container_name For example, to have a form share the same recordset as the form frmMaster, you would enter the following setting for the second form's RecordSource property: =frmMaster Using shared recordsets can also enhance performance, since they reduce the number of copies of the same recordset the application must maintain on the client. In addition, by sharing recordsets, forms automatically show any changes you enter. If you add a new employee but have not yet committed that change to the database, other forms sharing the same recordset can still display the new employee record you entered.
Q: Which OPO files do I need to deploy with my application?
A: When you compile your OPO application, you can choose to create either a standalone executable (.exe) or a separate application file (.po), which requires the OPO runtime file. In addition, if you are deploying a local database application, you must include the Blaze (.blz) file containing your data. If you are deploying a Client/Server application against an Oracle database, you must also include the ORACLE71.POD file on Windows or the ORACLE.POD file on Mac. If you are deploying a Client/Server application against Sybase or Microsoft SQL Server, you must deploy the DBLIB.POD file.
Q: Why would I want to create a separate application file?
A: If you are deploying a single application to a client, it makes sense to compile your OPO application to a standalone executable. However, if you are deploying many OPO applications to a single client, you can save on disk space by compiling each to a separate application file (.po) and including one copy of the OPO runtime.
Q: How do I build custom menus and toolbars in my OPO application?
A: There is not a graphical menu builder included with OPO v1.0, so you need to write code to create custom menus and toolbars. See page 2.17 of the OPO Sample Applications manual for an example. A graphical menu builder may be included with a future version of OPO.
Q: How can I display a custom toolbar, menu bar, or status line without displaying a form?
A: Currently, there are two obstacles to displaying a custom toolbar, menu bar, or status line without displaying a form: o the application closes as soon as the last window is closed; o custom menu bars, toolbars, and status lines must be associated with the currently active form to be displayed. If there is no active form, then the application cannot display the custom menu bar, toolbar, or status line. The solution to this problem is to create a form that disappears from the user's view, but does not disappear from the application. A splash screen that opens when the application launches is a prime candidate for this role. After the user presses the OK button on such a form, the application can hide it by calling the HideWindow() method. The form remains in memory but disappears from view, while the custom menu bar, toolbar, or status line associated with it continues to be displayed. Alternatively, the form could never appear at all: code added to the application's OnLoad() method could hide the form immediately, to avoid the step of displaying and then dismissing this form.
Q: How can I duplicate a menu command on a custom toolbar?
A: To add a toolbar button that, when pressed, performs the same action as when a user selects a particular menu command, you need to assign the same command code to the toolbar button as shared by the menu command. For example, if you create a custom menu command with a command code of 1001, a toolbar button must have 1001 as its command code to duplicate whatever happens when the user selects the menu command. The code you add to DoCommand() that tests for the value 1001 would then respond in the same way to both the menu command and the toolbar button. If you want to duplicate the functionality of a standard menu command, you need to assign the constant for that menu command as the button's command code. Appendix C in the Oracle Power Objects User's Guide lists these constants. For example, if you wanted to add a buton that closed the application, duplicating the File-Exit menu command, you would assign the constant CMD_QUIT as the button's command code.
Q: What choices do I have for adding graphics to my application?
A: You have several options, depending on what you want to do with the graphic. o If you want to store the graphic in a database, you should display it in a picture control. This standard control can be bound to a Long Raw column. o If you want to display the graphic through an OLE server application, you should add an OLE control to display the graphic. The OLE control can be either bound or unbound, and it can display both linked and embedded OLE graphics. o If you want to display a simple graphic in a form or report, you should import the graphic into Oracle Power Objects and then display it as the background of a form, embedded form, user-defined class, or pushbutton. You identify the imported graphic to be displayed through the object's Bitmap property.
Q: How can I display graphics with more than 16 colors?
A: Graphics displayed in a picture control or imported into the application are limited to 16 colors in the current version of Oracle Power Objects. To display a graphic with more than 16 colors, you can use an OLE control. The client system must have the appropriate OLE server application installed: for example, if you designate a graphic as a Microsoft Paintbrush picture, your system must have Paintbrush installed on it. The graphic can be either linked or embedded, or even stored in the database.
Q: How do I create controls dynamically?
A: In the current version of Oracle Power Objects, you cannot create controls dynamically. However, you can turn a control visible or invisible, to add or remove controls from a form. By setting the Visible property property of a control to False, the control disappears from the form, and the user cannot access it.
Q: How do I call a stored procedure from Oracle Power Objects?
A: To call a stored procedure, you use the EXEC SQL statement, which lets you run SQL code on any server to which you can connect through a session. For example, to run the stored procedure SP_CLEANUP, you would enter the following EXEC SQL statement: EXEC SQL AT MYSESS SP_CLEANUP You always need to specify the session first, before you run any SQL code through EXEC SQL. To capture a return set from a stored procedure, you need to run a larger block of code, in which you use a bind variable to assign values returned from the stored procedure.
Q: How many levels of nested Master-Detail relationships can OPO handle (e.g. Master-Detail1,Detail1-Detail2,...)?
A: OPO can handle an unlimited number of nested Master-Detail relationships.
Q: What is the max number of characters that can be inserted into a text box?
A: Millions of characters can be entered into a text box using the LONG datatype.
Q: How do OPO and Blaze integrate with other development tools?
A: Future versions of Oracle Power Objects will support OLE automation for integration with other programming tools. OLE Automation is key to our enablement of partners who will provide data modeling, CASE, version control, and testing tools for OPO. Oracle is also considering publishing an API for Blaze.
Q: Does Oracle Power Objects support OCXs and/or VBXs?
A: Power Objects supports only OCXs, the next generation standard for OLE custom controls. Version 1.0 supports only 16-bit .OCX controls.
Q: What OCXs are available now?
A: Hundreds of vendors are converting their existing VBXs to OCXs. Crescent, Crystal, Bits Per Second, and Apex, among others, all have OCX controls available now. Please contact the appropriate vendor for more information.
Q: Can a .DLL be called from OPO?
A: Yes. See the online help for how to call a .DLL.
Q: How can I launch another Windows application from OPO?
A: The Windows API procedure WinExec gives you the ability to launch applications. This procedure takes two arguments, the name and path of the application to launch (String), and a code for the state of the application window (minimized, maximized, normal, etc.). To launch the application normally, without minimizing or maximizing the application's window, you pass 1 as the second argument. To illustrate how to launch an application with WinExec, the following call to this procedure launches a hypothetical application: x = WinExec("C:\MYAPP\MYAPP.EXE", 1) Before you can call WinExec, you must declare its API in the Declarations section of the application's property sheet. The API declaration for WinExec looks like this: Declare Function WinExec Lib "Kernel" (ByVal lpCmdLine As String, ByVal nCmdShow As Integer) As Integer Since WinExec has a return value, you must capture it in a variable. The return value indicates whether the application launched successfully, and if not, the type of error that occurred. For more on this topic, please see the LAUNCH sample application and the Sample Applications manual.
Q: What are the extensability options on the Mactinosh?
A: The current release of OPO supports calling Code Resources. For information on how to do this, please see the Online Help section "Extensability on the Macintosh". (Future versions of OPO will support Code Fragments.) It is also possible to call Apple Events from OPO; for more information on how to do this please see the technical bulletin on calling Apple Events.
Q: Is Oracle Power Objects an OLE "server" or "container" application?
A: It is an OLE container application.
Q: Can an Oracle Power Objects application be inserted into an MS Word document?
A: No, this requires the ability to generate OLE Server applications, which no application development tool on the market will do this at the moment. The logical way to do this is to embed the Word document in the Oracle Power Objects application; this is supported, as Oracle Power Objects is an OLE container application.
Q: How can I add animation to my Windows application?
A: At various times, you may want to add animation to your application. For example, in a splash screen that appears when your application launches, you may want to display a brief animation. The easiest way to display animation is through an OLE control. However, this technique limits you to viewing the animation through the OLE server application. Before the animation plays, the server application (assuming it is installed) must itself launch and appear. Another option for displaying animation is to use the Windows API procedure bitBlt, which allows direct manipulation of graphics displayed in a Windows form.
Q: Does Oracle Power Objects support OLE and/or OpenDoc on the Macintosh?
A: OpenDoc support is planned for the next release of OPO.
Q: Where can I get more information on OPO?
A: The most current information on OPO is always available on the Oracle Web Server (http://www.oracle.com). If you wish to share information with other OPO Developers, there is both a Power Objects newsgroup on USENET and a Power Objects section on CompuServe in the Oracle User's Group Forum.
Q: What is the Object Marketplace and where can I get more information on building objects?
A: The Object Marketplace is Oracle's online
shopping center for Power Objects components. For
more information, send email to objects@us.oracle.com.
Q: Are there any books available on Oracle Power Objects?
A: Yes, there are currently three books
available on OPO (with more on the way*):
Q: Where else can I find information on OPO?
A: The Oracle Informant is a monthly magazine loaded with hints and tips on developing Power Objects applications. Call the Informant at 916.686.6610 or visit their Web pages at: http://www.informant.com/oracle/oi_index.htm.