• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1224
  • Last Modified:

UITextview clear when we select value from another viewcontroller in iPhone


        We are facing one problem, please make me nice solutions.....

        we have developed one form in iPhone for registration

        1) First Name
        2) Last Name
        3) Address
        4) Country
        5) State

       all above we take UITextview Control, When you Select Country and State then it goes new viewcontroller and select over the value from UITableView and return on registration page

     Problem: When we select value from next viewcontroller then come back on registration page then all First Name , Last Name and Address are clear

     Why it clear?? How to stable fill the value and we can easy select country and state??

     Please give me solutions how to store the value, after selecting country and state value??

     Thank you.....
  • 2
1 Solution
Hamidreza VakilianSenior iOS DeveloperCommented:
That's probably because you are creating a new instance of the viewcontroller which contains the first name, last name, etc. fields. Instead of creating a new instance you should display the instance of viewcontroller which was shown before.

Now I can help you even further if you upload your project somewhere; I can fix the things and explain the details for you.
citadelindAuthor Commented:
Please give me proper solution.

Thank you...
Hamidreza VakilianSenior iOS DeveloperCommented:
How do you display country and state view controllers?
a quick solution is to use presentModalViewController:

Featured Post

Take Control of Web Hosting For Your Clients

As a web developer or IT admin, successfully managing multiple client accounts can be challenging. In this webinar we will look at the tools provided by Media Temple and Plesk to make managing your clients’ hosting easier.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now