Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

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.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7701515
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T23:00:19+00:00 2026-05-31T23:00:19+00:00

I have 3 views view1, view2 and view 3. i have a problem of

  • 0

I have 3 views view1, view2 and view 3. i have a problem of changing a data in view 2 when i am in view 3. here are the ways i can think of

  1. pull the navigation controller stack, identify the view by iskindof test, take the variable and change it
  2. view 2 get the value from appdelegate and from view 3 i just update it in appdelegate and it works
  3. use a notification center and change the data.

which is the most advice way to change the data in my case.

the data is just a change to set of values to array of objects . .

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T23:00:20+00:00Added an answer on May 31, 2026 at 11:00 pm

    Option (1) is the approach with the highest risk of giving you a headache if you do any refactoring further down the line. It can be fiddly too, so there’s a risk of making mistakes and then having to expend more time to fix them. For these reasons, it may be best to avoid it.

    Choosing between (2) and (3) tends to provoke ideological debates about globals, encapsulation etc.

    There’s a lot to be said for (3), using UINotificationCenter, even if you don’t adopt the view that globals are evil. It encourages you to think very clearly about the communication protocol you are adopting, it prevents clutter in the the app delegate, it tends to be the most stable for refactoring, if you ever want to re-use the views elsewhere you have a head start etc.

    In particular, with well designed notifications, you often find that if you refactor further down the line you’ll have much less work – or even none – to keep your code running right.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i have a problem with switch view between 2 views with nib files !
I am having a problem with views. I have a view and am passing
I have the problem that my view controller class has too many delegates and
I have a very strange problem with a UITableview within a navigation controller on
I have a problem... In my view i have Image.If i click on image
Im having a very strange problem, i have a complicated view that returns incorrect
I have UIScrollView in my view. Problem is that if I slightly scroll it
I have a problem with the Create View in the SimpleRepository example in Subsonic
I have the following problem: I got a view with two text fields and
I have a small problem with UINavigationController animation between two view. My application build

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.