[archive] Grid control entry field editing

[Migrated content. Thread originally posted on 30 July 2008]

I have registered to the forum but am not able to post anything yet. I am waiting for the administrator to give me this right. In the meantime could you post the following question?


I want to use an Acubench grid control to enter transactions. Basically there are 4 visible columns and 13 rows. Row 1 being a header row.

Since the AcuBench help manuals indicate that each cell provides all function key feature of an entry field, I made the assumption that I would get all event procedure of an entry field as well. Apparently this is not so.

I have 2 questions. *

1. I would like to edit whatever the user types in the first column cells as s/he types it. In an entry field, I used the Ntf-Changed event. I am reformatting an account number to use ?-? between segments, e.g., the user type ?00? and now the entry field shows ?00-? with the cursor positioned after the ?-? ready to accept the next character. Thus the user enters digits ?000011234000? and sees ?00-001-1234-000?. Does anyone have any idea on how to go back to the COBOL after each key is pressed in a grid cell?

2. Does anyone know how to reposition the cursor in the cell after the added ?-? without highlighting the whole entry, as this would delete whatever was entered? This is done using the CURSOR property in an entry field.


In other word I am trying to simulate the Ntf-Changed event and CURSOR property of an entry field in a grid cell.


Thank you in advance for any help you can provide.