Working with O4W Entities in the OI10 IDE

In OpenInsight 10's new Integrated Development Environment (IDE), many types of OpenInsight entities have their own "designers" that can be used to create and modify their information.  This is even true for O4W entities, which are created and edited using the browser rather than desktop interface.  However, due to how the desktop and "The Web" communicate, it can sometimes be confusing to manage the O4W entities in this fashion.

When you choose File/New or File/Open from the IDE, you will see the O4W entities such as O4W Forms, O4W Reports, O4W Menus, and O4W Dashboards:


Selecting one of these entities will bring up one of the IDE browser windows, and will automatically attempt to connect to the web server to invoke the appropriate O4W wizard.  The communication parameters used to communicate with the web server are found in the Settings dialog, under IDE Settings, in the Engine Server section:


Unfortunately, unless a user is in the SYSPROG application, or the user remembers to manually update these settings in inherited applications under SYSPROG, the default connection will be to the engine server's built-in web server, using the virtual directory named "console."  This virtual directory will log in to the SYSPROG application, and ONLY the SYSPROG application; thus, even though the IDE may be running in another application, and thus other types of entities will be "local" to that application, by default only SYSPROG entities will be shown or created, and only SYSPROG tables will be accessible.

To avoid this confusion, users must always update the engine server settings shown above when creating a new application that will be using O4W.  The steps that should be followed after creating a new application are:

1. Create one or more users with the "O4W" or "Both OpenInsight and O4W" types in the Settings/Users/User Setup dialog:


2. Create the virtual directory to "point" to the new application. If using the built-in engine server exclusively, this involves updating the configuration file, which can be done from the Settings/Engine Server dialog, on the Web Server tab:


Be sure to fill in the details for the connection by double-clicking on the virtual directory name that you have added.  You should enter the application name, and (if using OpenInsight version 10.0.5 or later) you can enter "*" for the username and password; otherwise, enter the name of a user that has OpenInsight or "Both OpenInsight and O4W" types specified, and the associated password.  Be sure to save your updated information.

If using another web server instead of, or in addition to, the built-in web server, you must create a virtual directory in that web server (most likely pointing to the physical O4W folder in your OI 10 directory), and ensure that OECGI4 is the handler mapped to oecgi requests.  You must also update the connection details (for IIS, these are found in the Windows registry, under HKEY_LOCAL_MACHINE\Software\Revsoft\OECGI4).  You should create a new "key" for the new virtual directory – named the same as the virtual directory (that is, if your virtual directory is called "sample", then for IIS you should end up with a new Windows registry key HKEY_LOCAL_MACHINE\Software\Revsoft\OECGI4\sample).  The simplest way to create a new registry key is to edit the Windows registry (with for example REGEDIT), navigate to the OECGI4 subtree shown above, and choose "Export" from the File menu.  Save the selected registry branch to a local folder (such as c:\temp, or the Windows desktop) and use Notepad or a comparable editor to change the registry entry name (in this example, from 
[HKEY_LOCAL_MACHINE\SOFTWARE\RevSoft\OECGI4] to
[HKEY_LOCAL_MACHINE\SOFTWARE\RevSoft\OECGI4\sample]).  Also edit the information to set the ApplicationName to the name of the new application, and the UserName and UserPassword (to either the user name and password created for an OpenInsight or "Both OpenInsight and O4W" type user, or set both to "*" if running OpenInsight 10.0.5 or above).

3. Once more in the OpenInsight 10 IDE, open the Settings/IDE Settings/Engine Server section:


If running the built-in engine server on the current workstation, with the default settings, you need only change the virtual directory name to the new virtual directory name you've created above.  If using the built-in engine server on a different workstation, change the Engine Server URL as appropriate. Similarly, if you've changed any of the port numbers in the engine server's configuration, be sure to change them here as well.

If running another web server (such as IIS), change the Engine Server URL to the URL of the web server (you can also explicitly specify http:// and https:// prefixes).  Change the WebServer Port Number to reflect the port your web server is running on.  For http:// connections, this is normally 80; for https:// connections, this is normally 8080.

4. Restart the engine server (so that any changes you have made to the configuration are enacted)

At this point, you should be able to choose New or Edit on any of the O4W entities, and the appropriate designer FOR ENTITIES IN THE CURRENT APPLICATION should launch: