I have an array to store true answers and false answer of random frame multiple choices questions:
var arraytruefalseanswer=[];
I use push method to insert every true and false answer in the array:
arraytruefalseanswer.push(trueanswer)
arraytruefalseanswer.push(falseanswer)
The problem is: I can not remove the last element of arraytruefalseanswer .
Because If I use pop method arraytruefalseanswer.pop(), it will remove all elements in the array arraytruefalseanswer or bring back to arraytruefalseanswer=[]
If i use delete, it is still leaving null.
Please help... how can I remove the last element of arraytruefalseanswer using flash AS3? Thank you.
myArray = myArray.pop();(2) These are your Array options. Try using slice (startPos, endPos) likemyArray.slice(0, (myArray.length-1) );or try using removeAt (Pos) likemyArray.removeAt( myArray.length - 1);... where thatmyarrayis your own array's name and is also updated against itself like in step 1.if(XXX1jumlahbenar1_41BMID1 == XXX1jumlahbenar1_41BMID1++)... What does it do when it++an array? ... You can't sayif( myArray == myArray++) { do something };.. Finally Please put your content inside a MovieClip then travel in those frames likemyMC.gotoAndStop(x)because just usinggotoAndStop(x)alone makes the whole Stage change frames and you will have errors if your code tries to control something not existing in that frame.