1) masterReps3 was a typo. It should be: tempAssignedReps = masterReps;
2) masterReps is an array of names (i.e., John Smith, Jane Doe, etc.)
3) doBox() is called from a handler function of an RO that returns 'uname'. This is passed to doBox().
4) Yes, you would think that the tempAssignedReps.length = 0 after var tempAssignedReps:Array = new Array(); is redundant but this was my attempt to re-initialize the array. The array is not re-initializing after every call to doBox() -- that's the problem!
5)Yes, I meant splice, not slice...another typo.
Main Topics
Browse All Topics





by: zzynxPosted on 2009-10-28 at 01:01:59ID: 25680751
Too less code to be able to help you.
,1);
e.g. what is "masterReps3" in
>> tempAssignedReps = masterReps3;
When is doBox() called?
Remarks:
1) When your previous instruction is
var tempAssignedReps:Array = new Array();
the following
>> if(tempAssignedReps != null){
>> tempAssignedReps.length = 0;
>>}
seems rather obsolete to me.
2) slice()
Returns a new array that consists of a range of elements from the original array, without modifying the original array
So what's the sense of calling
tempAssignedReps.slice(cnt
without assigning it to something?
Also, the 2nd parameter is the end index, not how much elements to ...?
Oh, I see. Don't you mean splice() instead of slice()?