I want to show a date picker where the user will enter only month and year of the credit card expiry date.Is there any picker which will show only month and year options?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You probably need to make your own picker. You don’t have to subclass it or anything, though; just use a generic UIPickerView and return appropriate values from your
UIPickerViewDelegate/UIPickerViewDataSourcemethods.Or Here is a solution to get the same effect. For using this snippet of code you should replace UIPickerView to CDatePickerViewEx in nib file in “Custom class” of “Indentity inspector”.
.h file
.m file