ios - 登录用户信息的保存
黄舟
黄舟 2017-04-17 18:00:42
0
2
709

利用归档将用户登录信息保存在沙盒中自定义的plist文件中,退出登录时将plist文件删除,但是再次登录另外一个账号的时候会获取上一次的账号信息。然后退出程序再次进入才会获取正确的账号信息,求解!!

黄舟
黄舟

人生最曼妙的风景,竟是内心的淡定与从容!

reply all(2)
小葫芦

This kind of thing can be placed in NSUserDefaults

左手右手慢动作

removeItemAtPathThis method will return a Bool value, indicating whether it is successful or not. You can check whether you deleted it successfully.
Alternatively, you can also go to the sandbox and see if the file is still there.
If this file was deleted correctly, it should be impossible for this situation to occur, so the greater possibility is that you did not delete it successfully.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!