Getting a Pointer to a Field on a Scrollable Region

To get the pointer to a visible field on a scrollable region, use srf_ptr():

DFIELDPTR srf_ptr(data_row, data_col, srp)
 
int data_row;
/*Data row of scrollable region
*/
int data_col;
/*Data column of scrollable region
*/
SRPTR srp;
/*Scrollable region
*/

You can use the pointer to this field to access the data in the field or to change that field's options.

Note that srf_ptr() only returns the pointer to the specified field in the scrollable region. If you want to change options, installed functions, or other aspects of a whole row or column in the scrollable region, set up a loop and increment the data row and/or data column passed to srf_ptr().


Home Contents Previous Next