Highlighted

Flex Mobile: PersistenceManager not saving data (only on some iPads)

New Here ,
Jul 24, 2014

Copy link to clipboard

Copied

I have a function (save()) that saves a username after user login and a function (get()) that gets the username everytime the App is restarted so the user doesn't have to log back in and can work offline. This works on my iPad 2 and 3, but I have another iPad 3 that this does not work on. When the App is fully closed and reopened the "username" is not held onto. Is it my code or the device?

Example:

public var saveData:PersistenceManager = new PersistenceManager();

public function save():void

  {

saveData.setProperty("username", txtUsername.text);

  saveData.save();

}

public function get():void

  {

  var username:String = null;

  if(saveData.getProperty("username"))

  {

     //This comes back null on one iPad but not the others

  username = saveData.getProperty("username").toString();

  }

}

TOPICS
Development

Views

79

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Flex Mobile: PersistenceManager not saving data (only on some iPads)

New Here ,
Jul 24, 2014

Copy link to clipboard

Copied

I have a function (save()) that saves a username after user login and a function (get()) that gets the username everytime the App is restarted so the user doesn't have to log back in and can work offline. This works on my iPad 2 and 3, but I have another iPad 3 that this does not work on. When the App is fully closed and reopened the "username" is not held onto. Is it my code or the device?

Example:

public var saveData:PersistenceManager = new PersistenceManager();

public function save():void

  {

saveData.setProperty("username", txtUsername.text);

  saveData.save();

}

public function get():void

  {

  var username:String = null;

  if(saveData.getProperty("username"))

  {

     //This comes back null on one iPad but not the others

  username = saveData.getProperty("username").toString();

  }

}

TOPICS
Development

Views

80

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Jul 24, 2014 0
Adobe Community Professional ,
Jul 24, 2014

Copy link to clipboard

Copied

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jul 24, 2014 0