Consultor Eletrônico



Kbase 16692: ADM. Initial Value of Non-db Fields Reset in 8.1 Smart Objects
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   10/16/2008
Status: Unverified

FACT(s) (Environment):

Progress 8.1A
Progress 8.0A

SYMPTOM(s):

ADM. Existing applications that have non-database objects in their smartObjects might be affected

Applications operate off the screen-value (not doing an explicit assign)

When adm-display-fields is dispatched, the original value is displayed. This might cause the new value that is typed in to appear as if it is not sticking.

For example, assume you have a SmartBrowse that has a toggle-box (or combo-box, or fill-in) that is not associated with a database field. Based on the screen-value of the toggle-box, the query for the browse is opened in a certain way.

In Version 8.0A, the following code works fine and the value you type into the toggle sticks:

/* the value-changed trigger for the toggle */
/* note that allquery is logical defined in definitions section*/

ON VALUE-CHANGED of TOGGLE-1
DO:
ASSIGN allquery = INPUT toggle-1.
RUN dispatch ....
END.

/* in the local open query */
...
RUN dispatch IN THIS-PROCEDURE ('open-query':U).

/* code placed here will execute after standard behavior */

IF all-query THEN
OPEN QUERY (&browse-name} FOR EACH customer NO-LOCK.
ELSE
OPEN QUERY {&browse-name} FOR EACH customer WHERE customer.name BEGINS 'L' NO-LOCK.

...

In Version 8.0A, the above case runs based on the screen-value of the toggle-1 (it was never explicitly assigned), and the toggle-1 visually shows the value that was just typed in (checked or unchecked).

In Version 8.1A, the above case re-displays the toggle (because the new 8.1A adm-display-fields displays the non-database fields (as a result of the open query being done by default in the local-open-query) and, because the toggle is never explicitly assigned, it re-displays with its initial value.

Non-db fields screen values are not sticking (keeping their value)

CAUSE:

Behavioral change from Progress Version 8.0A to Version 8.1A that now displays both DISPLAYED-OBJECTS and DISPLAYED-FIELDS in the adm-display-fields. This did not occur in Version 8.0A.

DISPLAYED-OBJECTS is the list of non-database fields that are defined through the Unified Interface Broker (UIB)

FIX:

You can avoid this problem if you explicitly assign the toggle in its value-changed trigger so that you are not relying on the screen-value sticking:

ON VALUE-CHANGED of TOGGLE-1
DO:
ASSIGN toggle-1 = INPUT toggle-1
allquery = INPUT toggle-1.
RUN dispatch ....
END.