| Home | Tutorials | Forums | Articles | Blogs | Movies | Library | Employment | Press | Buy templates |
|
|
#1 |
|
Registered User
Join Date: Sep 2008
Posts: 1
|
Can I change the length of an array in flash?
Example: if(a==true) { array.length=5; } else { array.length=6; } |
|
|
|
|
|
#2 |
|
Senior Member
Join Date: Aug 2008
Location: India
Posts: 114
|
no not possible
|
|
|
|
|
|
|
|
|
#3 |
|
no idea!
Join Date: Aug 2008
Posts: 53
|
You could fill it with temporary values but I am struggling to think of any reason why you'd want to have an array lengh to differ from the actual amount of values contained.
What exactly are you trying to achieve - there may be a different way to do it? |
|
|
|
|
|
#4 |
|
The Flat One
|
I'm pretty positive that you can't modify the .length property directly like that, you'll have to look into:
http://www.adobe.com/support/flash/a...ionary072.html or http://www.adobe.com/support/flash/a...ionary064.html or http://www.adobe.com/support/flash/a...ionary062.html |
|
|
|
|
|
#5 |
|
Registered User
Join Date: Sep 2008
Posts: 6
|
Why would you need to change the length of an array. If you just want to add values use the .push method..
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| one template, many looks? | subquark | ActionScript 1.0 (and below) | 1163 | 12-22-2009 02:10 AM |
| Array of objects & web service - Flash converting array to a string | jeffcool | ActionScript 2.0 | 1 | 03-14-2005 07:31 PM |
| Streaming Flash Player 6 | simail | Other Flash General Questions | 7 | 04-03-2002 12:14 PM |
| Flash MX seminar | Tink | ActionScript 1.0 (and below) | 5 | 03-17-2002 05:41 AM |
| Php, Javascript, and Flash 5 browser detect and more! | Redline01 | Server-Side Scripting | 2 | 08-11-2001 02:09 AM |