Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在尝试将日期选择器添加到我的 iPad 应用程序中。如何将其添加为子视图?
这是我使用的
UIDatePicker *datePicker = [[UIDatePicker alloc] initWithFrame:CGRectMake(0, 40, 0, 0)]; // ... populate your date picker and format it as you see fit. [self.view addSubview:datePicker];