Xcode push and pop view to save data
===

I am trying to log data from the FirstView (one text field and one button) to SecondView (UiTableView) for example contacts list. I would like to briefly explain my code.

I have added a NavigationController with TabBar in the AppDelegate.m;

    UINavigationController *pointer = [[UINavigationController alloc] init];
    self.window.rootViewController = pointer;
    [pointer setNavigationBarHidden:NO];
    [pointer pushViewController:self.viewController animated:YES];

And I have used a `[self.navigationController pushViewController:push animated:YES];` to push the data to the second screen but it always go to another NavigationController view as loop with BACK button, then I have used  `[self.navigationController popToRootViewControllerAnimated:YES];` which it does not pass the data to the another view. Unless I close the program completely an open it back again. So is there a way to push and pop at the same time? Or could you please show me another way?

Thanks in advance.

Note I have shared my code in this link;
[Mycode][1]


  [1]: https://docs.google.com/document/d/1NEuMa7g5PRrF64-E8-5aRAG51cFQN8dutn3Wnfgz63o/edit