I\'d like to change the text from "Cancel" to "Done" of the Cancel button inside the UISearchBar in iOS 8. I am using UISearchControll
UISearchBar
UISearchControll
Here is Swift solution:
for (view) in _searchController.searchBar.subviews { for (subview) in view.subviews { if (subview.isKindOfClass(UIButton.self)) { let cancelButton = subview as! UIButton cancelButton.setTitle("BlaBla", forState: .Normal) break } } }