I am currently using this guide such that I can replace the root controller with another view controller. http://starterstep.wordpress.com/2009/03/05/changing-a-uinavigationcontroller%E2%80%99s-root-view-controller/
Currently, I have gotten that down on my app.
Consider the following scenario, View A (root) -> View B
On View B, there is a boolean value called firstLine (set to YES in viewDidLoad) which is used for a parsing algorithm. The algorithm works perfectly when we go into the view on the first time. (view A -> view B)
However, this new scenario breaks my parsing algorithm,
view A -> view B (pressed back) -> view A -> view B ( breaks )
This is where the boolean value (firstLine) is alternating weirdly when it is suppose to be set to YES when we first enter into the view. I am starting to believe that the first view B is still running on the background; thus, I tried popViewController but that didn't really work. It gave me a black screen, which is obviously what I don't want.
Any ideas?
EDIT: SOLVED
Turns out I was using an NSTimer and that kept on going off on its own. Therefore, I had to invalidate it when I left the view.