sahiti
sahiti

Reputation: 342

How do I create a drop down menu in iPhone app?

When the user taps on UITextField I want it to display a drop down menu with 5 or more options. When the user selects one of the options, it has to be set as the text of the text field. Any ideas on how to create it?

Upvotes: 0

Views: 1376

Answers (4)

Anil Kothari
Anil Kothari

Reputation: 7733

Drop down is not available in the iphone .Though there is an option of adding picker view inside the action sheet if you are making an application on iphone. and for ipad Application put a tableview inside a popovercontroller controller.

Upvotes: 0

yeforriak
yeforriak

Reputation: 1715

You can try try to use UIPicker

Upvotes: 0

Mudit Bajpai
Mudit Bajpai

Reputation: 3020

see this sampleCustomDropDownList

Upvotes: 1

Bob de Graaf
Bob de Graaf

Reputation: 2722

Create a UITableView I guess? With the 5 options inside. Then implement the didSelectRowAtIndexPath method of the tableview to set the text inside the textfield.

Upvotes: 0

Related Questions