There is usefull method of the Array object that you may find of use here.
Splice() allows you to splice a section of the array. The sintax
is arrayName.splice(startIndex,lengthToRemove,valuesToAdd).
If you use ButtonArray.splice(buttonToRemoveIndex,1) it will remove
that element of the array
The way it way described to me is, as long as you maintain one reference
to the object, it will be retained. The object is only destroyed when
all references to it are destroyed.
x = new Button();
mybuttons[7] = x;
to truly destroy the button object:
delete x;
mybuttons[7] = null; // or howev
Yeah, that's the easiest, and I did something
like that, although I ended up with about 20 lines of code, oh
well...
Cheers,Richard :o
[EMAIL PROTECTED]www.richardinfo.com(Everything running
on, and ported to the 19/12/2000 snapshot of DynAPI2)
- Original Message -
From:
Has anyone come up with a good way to deal wiuth
arrays?
I want to dynamically add and remove buttons from
an array of buttons..
How about a linked-list.. will this work alright in
this environment?
Or will a linked-list be too resource
intensive?
I don't want to have to cludge by array of
Hi..
I've a problem I'm trying to refresh a layer with dynapi and it works
correctly but i need to refresh it more than one time without refresh
entire document.
And if I don't reload entire document after the first refresh I can
refresh more.
Any suggestions?
--
Raul Perez, [EMAIL PROTECTE
Very nice,
shows what can be done with what's already avalable (the widgets).
And does not make you think your telco has cut you off because of
massive preloading (the price for the impressive zara site).
Would reset the popup menu after some 5 to 10 seconds of mouseout,
though.
Cheers, Martin