Consultor Eletrônico



Kbase 21850: How To Run a SmartDataObject Without Compiled Code (r-code)
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   3/1/2002
SUMMARY:

This Solution applies to Progress version 9.1C. It shows you how to execute an application that contains a SmartDataObject (SDO) that has no compiled code (r-code) associated with it.

When running an application that contains an SDO, if Progress cannot find compiled code (r-code) for the SDO because it was either removed from the System or cannot be found in a directory that is listed under the PROPATH, then you might see the following information message:

<sdo-file-name> SmartDataObject has no AppServer partition defined
and is running locally without proper database connection(s).

SOLUTION:

In order to eliminate this message and to be able to successfully run an SDO from the source code, you need to set a property named RunDOOptions in the SDO's container object. RunDOOptions can hold a comma-separated list of options that constructObject (in containr.p) uses to determine how to search for code when running Data Objects such as SDOs and SBOs.

Create an override version of the constructObject ADM2 procedure for the SDO's container object and insert the following line of code before standard behavior (RUN SUPER):

DYNAMIC-FUNCTION('setRunDOOptions':U, INPUT 'sourceSearch':U).

Set the RunDOOptions to "sourceSearch" in constructObject so that source code will be run when no compiled code (r-code) is found.

NOTE: When setting RunDOOptions within a SmartBusinessObject (SBO), it needs to be done within the main block of the SBO.