Highlighted
Absent Member.
Absent Member.
568 views

[archive] Is this possible?

[Migrated content. Thread originally posted on 11 December 2009]

Hi,

1. Users want to click on the 'Title' of one of the columns in a grid and made the grid get sorted according to the contents of that column, is this possible in Acu-Cobol?

2. Is it also possible to change the position of a column to take the position of other column in a grid, ex.grid has NAME TEL ADDRESS is it possible to change this order from inside the program to be TEL NAME ADDRESS?

3. Is it possible to put a seperator between lines(records) displayed in a listbox?

Thanks
0 Likes
2 Replies
Highlighted
Absent Member.
Absent Member.

RE: [archive] Is this possible?

1. Yes this is possible, we are doing it now, you just need to capture the Heading-Clicked event. Then initialize the grid and re-populate it sorted in the order of the column. It was easy for us because we are already using a temp file for our grids. So we just added keys to the temp file for each of the columns, and based on the column clicked you can start and read next to populate the grid. We also added descending and ascsending flags and display a little up/down arrow in the heading to spruce it up.
2. I don't know if this is possible, I haven't really attempted it. But I would also like to be able to do this behavior.
3. Not sure about this one.

Pretty much anything is possible given enough time and resources 🙂
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] Is this possible?

2 - Yeah, it's posible, we do it with the event in the grid msg-end-heading-drag (also there is an msg-begin-heading-drag) that tracks where you start to draggin the title and where you finish. With that, you only need to exchange positions of your columns in a table (at least we use a table to handle the properties of columns) and repaint the grid
3 - No, you can't, at least with a good margin of accuracy i asure it
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.