Kbase P83935: Field values are not saved in the database when a record is copied using the ADM2
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  07/10/2004 |
|
Status: Unverified
FACT(s) (Environment):
Progress 9.1D
SYMPTOM(s):
Copying a record does not save some field values using the ADM2
Using the Copy button of the SmartToolbar
Using the Save button of the SmartToolbar
Data-Target is a SmartDataBrowser
SmartDataViewer as Data-Target works fine
CAUSE:
MODIFIED property is not set to TRUE for the non modified fields.
FIX:
Add the following code in the collectChanges procedure in the SmartDataBrowser:
DEFINE VARIABLE cFields AS CHARACTER NO-UNDO.
DEFINE VARIABLE hField AS HANDLE NO-UNDO.
DEFINE VARIABLE i AS INTEGER NO-UNDO.
IF DYNAMIC-FUNCTION('getNewRecord') = "Copy":U
THEN DO:
ASSIGN cFields = DYNAMIC-FUNCTION('getEnabledHandles':U).
REPEAT i = 1 TO NUM-ENTRIES(cFields).
ASSIGN hField = WIDGET-HANDLE(ENTRY(i,cFields))
hField:MODIFIED = TRUE.
END.
END.