Skip to content

radhakrishnapai/RKDropDownTextField

Repository files navigation

RKDropDownTextField

CI Status Version License Platform

enter image description here

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Intro

RKDropDownTextField is a quick to install easy to use dropdown textField for iOS.

How to use

  1. Drag and drop a UIView into storyboard.
  2. Change its class to RKDropDownTextField.

enter image description here

  1. Set necessary attributes in the attributes inspector.

enter image description here

  1. Create outlet.

  2. Set delegate as the object which conforms to the protocol <RKDropDownTextFieldDelegate>.

  3. Populate values array with the possible dropdown values. enter image description here

  4. Implement delegate method

     - (void)dropDownTextField:(RKDropDownTextField *)dropDownTextField
       didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
     // Your code goes here
     }
    
  5. Set the property values with the possible values the list must contain.

You are done! Run the code and try tapping on the DropDownTextField.

Requirements

iOS 8.0. Objective C.

Installation

RKDropDownTextField is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod "RKDropDownTextField"

Author

Radhakrishna Pai, radhakrishnapai09@gmail.com

License

RKDropDownTextField is available under the MIT license. See the LICENSE file for more info.