Identify the columns of a browse
- Last Updated: April 29, 2024
- 2 minute read
- OpenEdge
- Version 13.0
- Documentation
Next, you need to know how to identify the columns in the Order browse.
The browse is a single ABL object with its own handle, but the columns in the browse
have handles as well. The browse acts as a container for those columns much as a frame
does for the fields and other objects it contains.
To get the handle to the first column in a browse, you use its
FIRST-COLUMN attribute. The chain of columns is linked by the
NEXT-COLUMN attribute of each column.
This next block of code for changeFields checks to see if the current
object in the frame is a browse. If it is, then it moves the browse to the left by
changing its COLUMN attribute, and widens it by six characters by
setting the WIDTH-CHARS attribute. It then walks through the columns,
checking each one’s data type. If a column is a date, it widens it by four characters.
You use the same DO WHILE VALID-HANDLE block header as for the frame
itself to walk through all the columns in the browse:
|
Finally, you need to remember to move on to the next object in the frame before ending
the original DO block:
|
The following figure shows what you see when you run the window.