UIDatePicker
- setDatePickerMode:设置日期控件的显示模式
- setLocale:设置是以什么国家的形式来显示,中国:zh_Hans_CN
NSDateFormatter内容,格式转换器
访问照相机,遵守协议:UINavigationControllerDelegate,UIImagePickerControllerDelegate
UIImagePickerController* imagePicker = [[UIImagePickerController alloc] init] 实例化图像选择控制器
[imagePicker setSourceType:UIImagePickerControllerSourceTypePhotoLibrary] 访问本地照片库
- setAllowsEditing:(BOOL)
设置代理 setDelegate
记住通过presentViewController展现图片控制器
- (void)imagePickerController:(UIImagePickerController*)picker didFinishPickingMediaWithInfo:(NSDictionary*) info
在调用此方法之前,先输出一下info,看里面的键值
最后要dismissViewController
pickerView
视图控制器要遵守DataSource和Delegate协议
列数和行数的设定,
- didSelectRow用来选定后返回数值的
- pickerView:(UIPickerView*) rowHeightForComponent:(NSInteger)component
间接设置Indicator的高度
setShowsSelectionIndicator:(BOOL) indicator是否可见
pickerView每一行可以返回UIView的,不局限于文字。