If it was a problem of code, seems to need a clean!!!
I however have made all clean procedure, but the problem is there...
The problem: I have added a right button (Tab Bar button) to a top Bar.
The left (back) goes perfect, but I cannot view the right button... He disappear when I make a build and execute the app!!!
Some idea?
Ps. In other UITableView of the project I have normally two buttons.
Related
I am working on an app using Xcode. When I am in the editing menu everything looks fine I am able to see the textfields and buttons however when I run the app on the simulator the image I have for the background comes to the front and hides everything else. Is there anyway to fix the background to the back and make it never come forward?
If you post any code could you please do it using SWIFT
In Interface Builder check the left sidebar and you will see the view hierarchy.
Just add your view as normal, then drag it up the view hierarchy to the top of the list in 'View' and it will be at the bottom of the stack.
Alternatively, Select the view in the Interface Builder, and then do Editor -> Arrange -> Send to Back
I am working on ToDoList app in IPAD.
I am getting problem to control+drag the button(Done, Cancel) to point to the "Exit" button in the bottom due to scroll issues.when i zoom-in in the story board for "Add To-Do Item" screen.I cannot see the below green button to connect due to scroll issues.
Will there be any other way i can point the "Done" or "Cancel" button clicks to unwindList segue.
Please provide me with any way to solve this issue.
Open the storyboard, click on the little icon in the lower left corner called "Show Document Outline" . You will see a list of elements with their names there. Control-Drag from the desired button name to Exit.
Also, right-click any view (including a button) will pop a small window with a full list (outlets and all). That window can be moved and dragged, so you can place it next to the green 'Exit' and drag from there. This comes handy when you need to control-click-drag from/to views that are far or tricky (without dropping it in the wrong place).
I think 'Touch up inside' is the click gesture.
I'm not sure when or how this happened in my project, but it did. The main button in the middle of my initial view controller ignores all touch events when I first load the app. The buttons in my navbar on the bottom all work fine.
If I follow one of those buttons through a modal segue to another view controller and then segue back into the initial view controller, the button works perfectly.
I'm at a loss. Any idea how this could have occurred or how I could fix it?
Update
I can't put my finger on what, but this has something to do with my constraints. If I remove them (and my app tumbles into a mess on 3.5 inch phones), the button works at all times.
I have the same problem: on the first load of the view one particular UIButton doesn't work, but if I tap on other tab bar element, launching a segue and then coming back to my home screen, it works perfectly.
My problem persists even if I remove every constraints for the view.
In my case, the POSITION of the button seems to be the cause of the issue: in the right side of the view it becomes not working, but if I move the same button on the center or left of my view it becomes available.
HELP ME/US :-(
I would like to know how I can add a back button to my UINavigationBar, I know that If I embed in a Navigation Controller in my main view, that all of this would happen automatically, but that is not what I am trying to do, in fact, the back button could go to any other view I connect the segue to, doesn't even have to be the back.
The back button needs to be the system navigation "back" button, I don't want to have to set image files for my buttons.
I tried dragging in a bar button item in storyboard but nothing shows up, doesn't seem to be doing the trick. The navigation bar was dragged to the view in storyboard (not created programmatically) and it shows up just fine.
I looked at the following similarly asked questions:
-> How do i add a 'back' button to a UINavigationBar manually?
-> How to add a button to UINavigationBar?
-> How to programmatically add a UINavigationBar and a back button on it
but they all point to just embedding the view in a navigation controller, which again, is not what I am trying to do.
If someone can please help me out, provide some sample code I would greatly appreciate it.
Try drag-drop a UIButton object. I have always added manual back button (hardly took the in-built one)
How do I reorder the initial view's tabbar controller elements without having to delete all the segues and re connect them manually in the desired order? Is there a way to change the order of these after they have been hooked up?
I was able to do this by just dragging them around in xcode 4.4 but that option seems to be non available in xcode 4.5.
Hopefully, this is possible from within the storyboard mode. But if it's only possible programmatically, that's ok too, just looking for any proper way to accomplish this without having to delete them all and re hook them up.
For example, how would I move the 'Home' item to first position?
The positions in each view are associated with the positions on the bottom bar of the Tab Bar Controller. If you reorder that bar you will reorder your views. You can reorder them by drag and drop on your interface builder.
In your example just select Home in your Tab Bar Controller and drag it to the first position.
If you have problems dragging and dropping try to select first your Tab View Controller or exit your XCode and open it again (like #thepumpkin1979 and #Rick pointed out).
Just edit the xml file and it will work.
Click on your "storyboard" and click the most right of the 3 buttons in "Editor".
This will show up an xml file on the left which u can edit anyway you wish.
Inside that file you should see xml tag "tabBar", inside it is "items", inside this is "tabBarItem".
All your tabBar items will be listed. You may cut and paste them in the order you wish.
I just did it now in Xcode 4.5.2.
Hope it also works for you too.
Ps. I am new to iOS so I can't use all the right Xcode names.
I think you can control+drag the tab item to reorder.
Drag and drop should work
You can drag the bar Item to the left to rearrange its position from the Storyboard.