【发布时间】:2012-12-15 04:05:54
【问题描述】:
我正在制作一个应用程序,我想用两个不同的 UIPickerView 填充两个 UITextView。
我的代码
控制器.h
UIPickerView *inputType;
UIPickerView *inputFormat;
controller.m
inputFormat=[[UIPickerView alloc] initWithFrame:CGRectZero];
inputType=[[UIPickerView alloc] initWithFrame:CGRectZero];
txtFormat.inputView=inputFormat;
txtType.inputView=inputType;
我的问题来了:
我想用不同的数据填充选择器,但我不知道该怎么做。
我知道如何为一个选择器设置数据源,但不是为两个。
我该怎么做?
【问题讨论】:
标签: objective-c ios datasource uipickerview