Kbase P101941: Label attribute does not work as expected when using dynamic buffers with temp-tables
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  3/3/2006 |
|
Status: Unverified
FACT(s) (Environment):
Progress 9.1x
SYMPTOM(s):
Label attribute does not work as expected
Using dynamic buffers with temp tables
Assigning a handle with the buffer of a temp-table causes handle-name:label
to display the temp-table.field name instead of the defined label
Same works fine with Progress version 10.0A or higher
CAUSE:
RCODE-INFORMATION qualifier is not used by default when defining the temp-table in Progress version 9.1x.
FIX:
Add the RCODE-INFORMATION qualifier when defining the temp-table. It determines wether Progress stores the temp-table buffer field actual
attributes in the r-code's initial value segment.
Example:
FUNCTION FnReadTT RETURNS LOGICAL (INPUT phTT AS HANDLE):
DEFINE VARIABLE vhField AS HANDLE NO-UNDO.
vhField = phTT:BUFFER-FIELD(1).
"Table" phTT:NAME SKIP(0)
"Number fields" phTT:NUM-FIELDS SKIP(0)
"Field name" vhField:NAME SKIP(0)
"Field label" vhField:LABEL SKIP(0)
"Field label" vhField:COLUMN-LABEL SKIP(0)
VIEW-AS ALERT-BOX.
END FUNCTION.
DEFINE TEMP-TABLE ttOuch RCODE-INFORMATION
FIELD Field1 AS CHARACTER LABEL "This is field 1"
FIELD Field2 AS CHARACTER LABEL "This is field 2"
FIELD Field3 AS CHARACTER LABEL "This is field 3".
FnReadTT(TEMP-TABLE ttOuch:DEFAULT-BUFFER-HANDLE).