objective c - if parentViewContoller statement -


I am writing a program with a UITTable Weave and adds buttons to the navigation bar, which leads to an edit page is. When you click on an item in the table, a view (RAVI) is pushed with information related to that item. This view has an editing button that goes to the editing page. Is there any way that I can put an if statement for the button on the edit page, which says, "If the Peritueview Controller is UITableView, go to the Revview, and PopWeb Controller?" I think there is a way to do this, but to do this, I am not sure about the syntax. If I understand correctly, then you have a UI navigation controller and press it

  • A "EditController"
  • But there is a possibility that step 2 is omitted and you go directly to the editing screen.

    Now that the last controller has popped up, you want to be able to go always for "RViewController", even if it is not on the stack.

    First of all, Parental Control is not the last controller on the controller stack, but the UI is the controlling controller, so there is nothing to do with the current problem.

    The way to do this is by setting the view of the UIAV controller with the explicitly an NSArray property of the controllers. I have not tried to do this but it should work:

    When a user clicks the "Add" button instead of pushing the Edit View Controller, do something like this:

    < Pre> NSArray * stack = navigationController.viewControllers; Navigation Controls ViewControllers = [Stack arraybasing object: RVIUI controller]; [Navigation Push ViewController: Editing: Controller Animated: Yes]; (By the way, I suggest that names like "revue" can not be used, but perhaps for very short-term local variables, such as in a loop. Descriptive names Use cocoa idiom and you will help a lot for a long time.)


    Comments

    Popular posts from this blog

    c# - How to capture HTTP packet with SharpPcap -

    php - Multiple Select with Explode: only returns the word "Array" -

    php - jQuery AJAX Post not working -