IMPORTANT ANNOUNCEMENT

These forums were permanently set to read-only mode on July 20, 2022. From that day onwards, no new posting or comment is allowed on the site, but the historical content remains intact and searchable.

A new location for posting questions about PlanetPress Suite is now available:

OL Learn - PlanetPress Classic (opens in new tab)

Topic Options
#20738 - 08/29/07 02:20 PM array questions
RobertE Offline
Member

Registered: 06/14/07
Posts: 32
Is there a way to:

1.) resize an array as it grows?

2.) clear a global array object between datapages so the old data goes away, and the array can be reloaded when the data page changes.

Thanks for your help

Top
#20739 - 08/29/07 04:06 PM Re: array questions
Anonymous
Unregistered


Hello,

PlanetPress Talk arrays are static.
In order to 'clear' an array, you can use a loop to assign a certain value for every individual element of the array(0 for an integer array, '' for a string array, or any other value you determine). For example, in the 'PressTalk Before' of the page, you can do something like this(for a string array declared as 'GlobalVariable1' with a size of 5 elements ) :

define(&i,integer,1)
for(&i,0,1,4)
&GlobalVariable1[&i] := ''
endfor()

The arrays are zero-based.
Thanks.

Pierre P

Top
#20740 - 09/04/07 09:58 AM Re: array questions
RobertE Offline
Member

Registered: 06/14/07
Posts: 32
Thank you for the information. I already had that in place, but was hoping for some built-in functionality that would allow me to reset the array or at least assign it to an empty array. Will move forward with the above code.

Thank you,

Robert

Top


Moderator:  cosimo, OL Newsgroup Support