Using SharedObjects : SharedObject « Development « Flash / Flex / ActionScript






Using SharedObjects

 
package{
  import flash.display.Sprite;
  import flash.net.SharedObject;  
  public class Main extends Sprite{
    public function Main(){

        var hiscores:SharedObject = SharedObject.getLocal("hiscores");

        hiscores.data.highest = 999999;
        if (hiscores.data.scores){
            for (var i:int = 0; i < hiscores.data.scores.length; i++){
                trace(i + ": "+ hiscores.data.scores[i]);
            }
        }
    }
  }
}

        








Related examples in the same category

1.OverflowTest