on this post, 10 years ago!!, @Admin makes reference to KB 21024, and KBP9248:
community.progress.com/.../2280
I want to change format to a dynamic browse column, but haven't found how, and neither those kbs, nor the original answer are to be found...
You can adjust the format of a column in the row-display trigger.
CREATE BROWSE hBrowse ASSIGN X = 17 Y = 63 WIDTH = 90 DOWN = 14 FRAME = FRAME {&frame-name}:handle READ-ONLY = YES SENSITIVE = TRUE ROW-MARKERS = TRUE SEPARATORS = TRUE FIT-LAST-COLUMN = TRUE FONT = 1 TRIGGERS: ON DEFAULT-ACTION DO: IF AVAILABLE(ttClienteNombre) THEN DO: ASSIGN pSeleccion = ttClienteNombre.cliente. APPLY "GO":U TO FRAME {&FRAME-NAME}. END. END. ON ROW-DISPLAY DO: hColumn = hBrowse:GET-BROWSE-COLUMN(1). hColumn:FORMAT = "X(40)". hBrowse:GET-BROWSE-COLUMN(2):FORMAT = "X(15)". hBrowse:GET-BROWSE-COLUMN(2):FORMAT = "X(16)". END. END TRIGGERS. CREATE QUERY hQuery. hQuery:SET-BUFFERS(BUFFER ttClienteNombre:handle). hQuery:QUERY-PREPARE(cBaseQuery). hQuery:QUERY-OPEN (). hBrowse:QUERY = hQuery. hColumn = hBrowse:ADD-LIKE-COLUMN ("ttClienteNombre.Nombre"). hColumn = hBrowse:ADD-LIKE-COLUMN ("ttClienteNombre.RFC"). hColumn = hBrowse:ADD-LIKE-COLUMN ("ttClienteNombre.Cliente"). hBrowse:GET-BROWSE-COLUMN(1):Width = 35. hBrowse:GET-BROWSE-COLUMN(2):Width = 15. hBrowse:GET-BROWSE-COLUMN(3):Width = 10.
This is it.... to no avail. It chaged column-with, but not format as names (Nombr) is truncated on display.
I believe you have to change the format of the field (rather than the browse's column) before the column is dynamically added to the browse (using ADD-LIKE-COLUMN).
Something like:
ASSIGN BUFFER ttClientNombre:BUFFER-FIELD("RFC"):FORMAT = "X(15)" BUFFER ttClientNombre:BUFFER-FIELD("Cliente"):FORMAT = "X(16)".