Search code examples
blackberrydata-persistence

destroy persistance from blackberry


I use PersistentObject to store login and password to enter directly in the application when I want to delete the values I use PersistentStore.destroyPersistentObject(Info.KEY); But the values still exist. Should I add something?


Solution

  • To destory the persistent object you should call PersistentStore.destroyPersistentObject(key) . It can throw ControlledAccessException if the caller does not have the permission to do it. Make sure you are calling the same key you are expecting to be deleted.