vendredi 11 septembre 2015

Modifying Array Data

I have to constantly add data to my NSMutableArray to index 0.

  MyVariables.MutableChatUser.insertObject(MyVariables.username, atIndex: 0)

Problem: The code above works perfectly the first time around but then next time it runs it overwrites the previous data.

Goal: I want the array to push the previous value from index 0 to index 1 when inserting a new value at index 0. I dont want to stomp on any existing data in the array



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire