如何在 xcode 4.2 故事板中使用 UIPickerview?

发布于 2024-12-23 16:38:45 字数 61 浏览 1 评论 0原文

我正在尝试在我的项目中使用 UIPickerView,但我不知道如何以故事板格式使用它们。有谁知道该怎么做?

I am trying to use a UIPickerView for my project but I can't figure out how to use them in the storyboard format. Does anyone know how to do that?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

清眉祭 2024-12-30 16:38:45

这篇文章将带您完成 xcode 4.2 的整个过程

UIPickerView - 如何填充

This post takes you through the process w/xcode 4.2

UIPickerView - How to populate

翻了热茶 2024-12-30 16:38:45

我验证了它对于故事板的行为与对于 xib 文件的行为相同。将 UIPickerView 添加到视图后,右键单击它以显示 delegatedatasource 出口。仔细检查视图的 UIViewController 是否是 UIPickerViewDataSourceUIPickerViewDelegate,否则您将无法附加这些插座,除非是。

I verified and it behaves the same for storyboards as it does for xib files. After adding the UIPickerView to a view, right click it to reveal the delegate and datasource outlets. Double check that your UIViewController for the view is a UIPickerViewDataSource and UIPickerViewDelegate, or you will not be able to attach these outlets unless it is.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文