Re: Calling set_count from within the INPUT ARRAY statement??
Posted in 1995
Mike Reetz (miker@ncar.ucar.edu) wrote: : I need to be able to alter the number of filled rows in a program array : while inside the INPUT ARRAY. : ... : It seems that even though I call set_count() : (with the new number of filled rows) from within the INPUT ARRAY it does : nothing (or at least not what it should). I think you're going to have to leave/reenter the array via a WHILE loop in order for set_count() to take effect. The FAQ has examples of this in relation to emulating a NEXT ROW sort of thing. Another solution that may be acceptable to you is to call set_count() with the max size of the array, rather than the number of rows you've filled in (i.e.: you have and array of size 100 and fill in 30 rows at the start, you still CALL set_count(100)). This is suitable if the user does *not* use the INSERT and DELETE keys, but rather only adds rows at the bottom of the filled-in area (and via your ":r" trick), and deletes either not at all or via ON KEY. ======================================================================= Dennis J. Pimple dennisp@informix.com Opinions expressed Senior Consultant -------------------- are mine, and do not Informix Software Inc Voice: 303-850-0210 necessarily reflect Denver Colorado USA Fax: 303-779-4025 those of my employer.