The O$Converter is run after the Omnis 7^3 library is first opened in Omnis Studio and the automatic core conversion process has completed. For this release of the conversion tool the post conversion tasks that will be performed are:
The Omnis 7 Analyzer will have previously fixed any class names that would not be valid in the OMNIS Studio environment. References to classes whose names were changed must be modified:
This task is performed by "ModuleAClassNames".
If you copy a field to the clipboard in the OMNIS 7 window editor and then paste the field into the report editor, then the method associated with the field is copied to the report. When you convert the OMNIS 7 library to OMNIS Studio then that method is converted to a $print method, either associated with the original object or possibly another object on the report. The purpose of this module is too delete all $print methods belonging to report objects (fields and section markers) that have been created in this way. Since it was not possible to add a method to a report using the OMNIS 7 report editor all $print methods found will have been created in this way.
This task is performed by "ModuleBReportFields".
Change OMNIS 7^3 table notation to use the equivalent OMNIS Studio notation items:
Note that since there is not a one-to-one correspondence between the OMNIS 7 notation such as $was_rowobjs and $objs, some occurences are not fixed. A warning message is generated for these.
This task is performed by "Submodule_MethodsANotation".
Change OMNIS 7^3 notation to use the equivalent OMNIS Studio notation items:
This task is performed by "Submodule_MethodsANotation".
Remove any redundant "Quit method" commands at the end of methods that do not return a value.
This task is performed by "Submodule_MethodsBQuitMethd".
This submodule replaces notation that uses field idents with the name of the object ($name property).
This task is performed by "Submodule_MethodsCFldIdent".
This submodule converts Close Window Instance and Close Top Window commands into a notation equivalent. This fixes a compatibility issue since the Close Window Instance/Close Top Window commands in OMNIS Studio change the status of the flag whereas they did not in OMNIS 7.
This task is performed by "Submodule_Methods_CloseWind".
Remove the following redundant comments inserterd by the built-in converter containing the text "COMMAND REMOVED BY CONVERTER":
This task is performed by "Submodule_Methods_CommentLn".
Locate and log all missing extensions for subsequent manual fixing by the user:
This task is performed by "Submodule_Methods_Extension".
The Omnis 7 Analyzer will have previously fixed any window field names that would not be valid in the OMNIS Studio environment. References to fields whose names were changed must be modified:
This task is performed by "Submodule_Methods_FldName".
This submodule converts certain commands that use tab order to manipulate fields on windows with equivalent notation commands. If possible the field will be referenced using its $name property. If a number of fields are manipulated using a range (say field number 6 to 9) then if the range does not exceed a preset threshold, then the command will be converted to reference each field within the range. Otherwise the notation method "$sendall" is used to manipulate fields within a From and To range of $order. Note that this approach has the disadvantage that changing the tab order of the fields on the window will have an effect on the fields modified by the notation command whereas the first 2 approaches remove this dependency.
This task is performed by "Submodule_Methods_HideDisab".
This submodule converts Hide, Show, Enable and Disable field commands to notational equivalent. The reason for doing this is that OMNIS Studio will generate a run time error when a Hide, Show, Enable and Disable field command specifies an object name that does not exist on the top open window instance whereas OMNIS 7 did not. Conversely the notational equivalent generated by this module will simply ignore any objects that do not exist.
This task is performed by "Submodule_Methods_HideToNot ".
Replace Obsolete Commands with OMNIS Studio equivalent:
This task is performed by "Submodule_Methods_ObsoleteC".
Change open window handling so that only one instance of each window class may be opened:
This task is performed by "Submodule_Methods_OpenWind".
Converts #MODIFIED into a notational form. Note that this change is not strictly necessary since the OMNIS 7 #MODIFIED system variable continues to work with OMNIS Studio
This task is performed by "ModuleEHashModified".
Process all the methods that are window field event handlers and are also being used as called methods. This will not work in Studio because the methods will be converted by the core converter to field $event methods and the call to the method using its original Omnis 7 name will fail with a runtime error because a method of that name no longer exists. We need to create a new window class method for each one and move the code from these $event method to the new method and create a call to the new method from the $event method.
This task is performed by "Module_CalledEventHandlers".
Replace calls to methods in selected classes with calls to code class methods or to the class instance.
This task is performed by "Module_CallMethod".
Replace Omnis 7 event handling with equivalent Omnis Studio code.
This task is performed by "Module_EventHandling".
Remove redundant redraws (in $construct method and repeated in same block of code) and replace Omnis 7 style redraw commands and redraw options on Calculate commands with equivalent Studio command:
This task is performed by "Module_FieldRedraws".
Change all Field Reference parameters that set initial values in their parameter definition to use an explicit calculate command to set the value, since using initial value with field reference parameters doesn't work in Omnis Studio. This module extracts the initial value from the parameter variable definition and inserts a new line of code at the beginning of the method that calculates the value into the variable.
This task is performed by "Module_FieldRefParms".
Fix indirect menu options:
This task is performed by "Module_IndrectMenuOptions".
This module will fix the problem associated with use of library variables and multiple libraries. Omnis 7 library variables are converted by the built-in core converter in Studio to task variables that have a different scope. To correct this in a situation where an application comprises more than one library using this converter module the developer must nominate a master library. Other libraries are then regarded by this module as children of the master library. All task variable definitions are copied from the child libraries to the master library. Since there is only a single Startup_Task instance all these variables effectively become global variables that are available to all instances.
This task is performed by "Module_LibraryVariables".
This module fixes properties of List fields and Complex Grids on window classes where the display or behaviour is different to that previously exhibited in OMNIS 7v3. Vertical scroll bars are added to all list fields and $canresizerows set to kFalse for all complex grids.
This task is performed by "Module_ListField".
This module reads all records in fLostProperties file and attempts to change the relevant property of indicated object. This is done because the values of some Omnis 7 object properties are lost during the core conversion process.
This task is performed by "Module_LostProperties".
On the Macintosh platform certain fields such as pushbuttons only generate #CLICK events. Therefore it is common practice for Mac only applications to omit the code that checks for a specific event. This module adds 'On evClick' commands to event handlers for Push button, Button areas, Radio buttons and Checkboxes where there was previously no such check. This is to make applications that were written to run only on Macintosh work properly under Windows.
This task is performed by "Module_MissingOnEvClicks".
In some Omnis 7 applications each format has a special procedure that is used to declare Format variables, does not contain any other code and is not normally called by other procedures. The O7Analyzer identifies such procedures and sets a flag for each in the fProcs file. After processing by the core converter the Format variable commands are removed resulting in empty and redundant methods. This module reads all records in fProcs file and removes these methods.
This task is performed by "Module_wOnlyFormatVarDefs".
When a Prompted Find command is executing in Omnis 7 events such as #BEFORE, #AFTER are not generated when the user tabs in and out of entry fields. However in Omnis Studio these events are generated and this can cause problems with existing code. For example an evOK will occur when the user terminates a "Prompted find" command by pressing the Enter key. This module suppresses processing of certain events in the window $event method and field $event methods of window classes that contain a "Prompted find" command. behaviour of the application consistent with the way that it previously behaved in OMNIS 7v3.
This task is performed by "Module_PromptedFind".
Ensure that all parameter variables are initialised:
This task is performed by "Module_UninitedParms".
OMNIS 7 libraries that are converted to OMNIS Studio using the built-in converter display a different combination of foreground and background color in background objects on window classes. Also the width of Omnis 7 labels is often insufficient to accomodate the text to be displayed which results in truncation. This module can be used to set the back pattern, backcolor, forecolor and width properties of all window background objects. You can change the pattern, color and width used to suit your requirements.
This task is performed by "Module_WindowBobjs".
Fix any conversion issues relating to fields on window classes:
This task is performed by "Module_WindowStyles".
This module sets window objects to default styles and windows' themes. The styles are copied in from library O$Styles.lbs that must be in the same folder as the O$converter.
The module can also perform the following tasks by setting the flags in the $construct method of Module_WindowStyles:
This task is performed by "Module_WindowFields".
Remove any blank lines found at the begining of a method.
This task is performed by "Module_xRemoveBlankLines".
The Omnis 7 Analyzer will have previously fixed any method names that would not be valid in the OMNIS Studio environment. References to methods whose names were changed must be modified:
This task is performed by "Module_yMethodNames".
Note that some additional tasks may be performed by modules included with the shipped version of the O$Converter. See the About window for a full list of all modules included.
Extending The Conversion Tool Functionality is achieved by adding additional modules to those already provided.
See also Pre Conversion Tasks..