GDDM V3R2 Base Application Programming Guide
Previous topic | Next topic | Contents | Index | Contact z/OS | Library | PDF | BOOK


Querying the position of the alphanumeric cursor, using ASQCUR

GDDM V3R2 Base Application Programming Guide
SC33-0867-01



In an alphanumeric application you can query the cursor position, by using this call:


     CALL ASQCUR(CODE,F_IDENT,ROW,COLUMN);  /* Query cursor position */

If you set the first parameter (CODE) to 0, GDDM sets ROW and COLUMN to the page coordinates of the cursor; that is, its row and column numbers within the page.

If you set CODE to 1, the cursor position is returned in field coordinates. F_IDENT is set to the alphanumeric field identifier and ROW and COLUMN give the row and column position within the field.

If field coordinates are requested but the cursor does not lie within a field, F_IDENT is set to 0 and page coordinates are returned.

Where the above descriptions refer to the position of the cursor in the field, they mean the field on the screen, as opposed to your program's description of the field. In most cases, there is a one-for-one relationship between each character position of the field on the screen and each character position of the field in your program. An exception to this, and the use of ASFCUR and ASQCUR in that context, are described in "Using procedural alphanumerics for double-byte characters" in topic 13.6.

Subtopics:

Go to the previous page Go to the next page



Copyright IBM Corporation 1990, 2012