How to save a BOOL in iOS app -


i used following code save bool it's not working.

[[nsuserdefaults standarduserdefaults] setbool:yes forkey:@"save"]; strongman = [[nsuserdefaults standarduserdefaults] boolforkey:@"save"]; 

are there other ways save bool?

you should add following code

[[nsuserdefaults standarduserdefaults] synchronize]; 

Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -