I'm trying to display time picker dialog by using showDialog(1);
when radio button is clicked. But i cannot display if i write onclick event for radio button. How to solv this problem? Any help is appreciated and thanks in advance...
RadioButton r;
r.setOnCheckedChangeListener(listener){
@Override
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
// add your dialog here
}
}
YOu follow the link to get to know about the date picker: http://www.androidpeople.com/android-datepicker-dialog-example
you just have to replace the button date to the radio button, note the id used in the button should be same as that in the radio button.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.