[Stackoverflow] [Progress OpenEdge ABL] What's the meaning of X16 or X45 (format specifiers) in Progress-4GL?

Not open for further replies.


I'm heavily struggling with some format specifiers in Progress-4GL, release 11.6, based on appBuilder and procedure editor.

In order to understand what's happening, I'm doing the following in the source code:

MESSAGE "Detail: Table1.Field1=["  Table1.Field1  "], STRING(Table1.Field1, X16)=["  STRING(Table1.Field1, "X(16)")  "]" VIEW-AS ALERT-BOX.
MESSAGE "Detail: Description=["  Description  "], STRING (omschr, X45=["  STRING(Description, "X(45)")  "]" VIEW-AS ALERT-BOX.

The result looks more or like like the following (I've put the information on different lines for readability, I did not modify the content of the square brackets:

Detail: Table1.Field1=     [ 000976 ],
STRING(Table1.Field1, X16)=[ 000976           ]  <= length=18 characters!

Detail: Description=[ Aldente ], 
STRING (omschr, X45=[ Aldente                                       ]  <= length=47 characters!

As you can see, the fields inside the tables start with a space and end with one. Whether this is correct or not, I don't care. What I expect, is the formats X16 and X45 to create strings of length 16 and 45, not 18 and 47.

Does anybody know what's happening here?
Thanks in advance

Continue reading...
Not open for further replies.