I am after some advice on the best way to do this.
I have a form with 3 columns by 10 rows of fields, which is a window
into 100 rows.
The user scrolls up/down by 10 rows at a time.
Columns 1 & 2 are fixed length (only the data changes).
Column 3 is an input field.
My app is VERY TIME sensitive.
When the user scrolls, I have to update all the fields.
Initially I filled the event queue so in order to reduce the number of
events, I set the fields in columns 1 & 2 to point to my array (using
FldSetTextPtr). That way, I can update any of these values
directly and do a FrmDrawForm to refresh the screen.
Question 1: Is this legitimate ?
Since the pointer is to my array these should remain persistant ???
Column 3 fields are user updateable, so I use FldDirty to see if the
field has been changed, and if so I do FldGetTextPtr, StrCopy to my array,
and FldSetDirty false. To update the fields (all 10 during
a scroll, etc) I do a FldFreeMemory, a FldInsert, and FldSetDirty false.
Question 2: Is this legitimate ? Is
there a better way ?
I save the FrmObjectPtr for all fields in an array when the form is
first loaded. The form is never removed (I do FrmPopupForm
and FrmReturnToForm).
Question 3: Is this legitimate ? Is
the FrmObjectPtr always persistant throughout the life of the form ?
Any help or comments would be appreciated. Something I am doing is wrong as gremlins0 does indeed crash after about 3000 loops.
Thanks in advance,
Ray
