I need to access (read/write) some variables in all of my views.
The variables will be defined in view 1, then used and set to a new value in view 2.
How can i do this?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Ya , there is much a easy way to handle this…..
You can take a Global Variable
In your Delegate.h file declare your variable:
Secondly in Delegate.m file
Synthesize it over here..
This is Done .Now you can use this String Variable in All/any class you want..
To use this Global Variable.
Just import you Delegate file make the obj of it….
Now in Your class.m
Now you can access it anywhere in your class by this Object:
Just follow my Steps Carefully After giving so much pain to my finger, I am sure this is definitely going to help you…..
Have a easy life,