How do you delete all elements in an Array?

Become a member of the CGSociety

Connect, Share, and Learn with our Large Growing CG Art Community. It's Free!

THREAD CLOSED
 
Thread Tools Search this Thread Display Modes
Old 06 June 2011   #1
How do you delete all elements in an Array?

I simply want to clear out everything in an array.

There are thousands of things that get put into this array, so using deleteitem 1,2,3,4,5......is just not going to happen. Any ideas?
 
Old 06 June 2011   #2
Set the array.count value to 0 or #().
Code:
array.count = 100 #(undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, undefined, ...) array.count = 0 #() array = #() #()

-Eric
__________________
"The Evil Monkey hiding in your closet."
 
Old 06 June 2011   #3
Woooooowwwwwww I'm dumb lol. Shows how much I know about arrays. Thanks a ton though Eric!
 
Old 06 June 2011   #4
Thread automatically closed

This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
 
Thread Closed share thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
CGSociety
Society of Digital Artists
www.cgsociety.org

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump
Miscellaneous

All times are GMT. The time now is 08:54 PM.


Powered by vBulletin
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.