开发者

Creating drop down option on text box in xcode

In my app i am planning to enter my input through a text box .Once entered the input i will be able to get all the data or words corresponding to it from my database .Is there any option to get drop down box from text box or i have to use table view controller only 开发者_Go百科to display my output.Any help will be greatly appreciated.

Thanks, Christy


You can use UIPickerView, its mostly used as a dropdown menu in iOS. But again, its mostly used as an input source. You can go with table view as a standard approach.


You can use an UISearchBar and UISearchBarDelegate and update an UITableView. To get the idea look at the contacts app in your iPhone.


You can use UIButton(custom) and set background image with combobox image(you can get from google or create thorough GIMP in MAC), if user presses the button,show UIPIckerview below the button or at the bottom of iphone screen or wherever you want.after selecting value from it, you can hide pickerview and change the title of UIButton.you can achieve this through tableview also.


I know it's a bit late in the day but, for anyone else looking for drop down list functionality, I came across this, which appears to do the trick: http://www.addimage.net/blog/post/2012/04/11/Apple-iOS-Drop-Down-Menu-class.aspx

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜