Kbase P98964: Initially non enabled fields do not change the state of the toolbar when they are updated
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  10/3/2005 |
|
Status: Unverified
FACT(s) (Environment):
Progress 9.1D
SYMPTOM(s):
Inconsistent behavior with widgets in Smart Data Viewer
Adding your own widgets to a Smart Data Viewer, initially not enabled
valueChanged internal procedure fires when widget is updated
The toolbar does not change its state when the widget is updated
CAUSE:
The 'fieldModified' routine (datavis.p), which is responsible for setting the 'dataModified' property states that "The passed field must be in the list of EnabledFields or EnabledObjFlds."
These fields are normally set at initialization and contain a list of fields that are used to determine whether a field should affect, and be affected by, the viewer and toolbar 'state' mechanisms.
FIX:
To include the widgets in one of these lists you must either enable it initially or add it to the respective list.
Add the following code to the routine used to enable the widget :
DEFINE VARIABLE cEnabledObjHdls AS CHARACTER NO-UNDO.
{get EnabledObjHdls cEnabledObjHdls}.
cEnabledObjHdls = cEnabledObjHdls +
(IF cEnabledObjHdls NE "" THEN "," ELSE "") +
STRING(FILL-IN-1:HANDLE IN FRAME {&FRAME-NAME}).
{set EnabledObjHdls cEnabledObjHdls}.
As a general rule, if the field can be found in the related SDO it should be added to EnabledHandles, otherwise, add it to EnabledObjHdls.