c# - 我如何在表单上从 iOS 和 Android 打开 UIViewController

标签 c# ios xamarin cross-platform xamarin.forms

单击表单 View 上的按钮,然后:

如果是 iOS

从 iOS Storyboard打开一个 UIViewController

如果是机器人

安卓也一样

实际上,我只需要 iOS...

最佳答案

通常您只需在 PCL 项目中定义一些接口(interface),然后在使用 DependencyService 链接它们的平台特定项目中实现它。 http://developer.xamarin.com/guides/cross-platform/xamarin-forms/dependency-service/

关于c# - 我如何在表单上从 iOS 和 Android 打开 UIViewController,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28829569/

相关文章:

javascript - 如何在完全信任的解决方案中通过 javascript 调用 Sharepoint 2013 API?

c# - .NET API 文档是否应该定义/公开枚举成员的文字(数字)值?

c# - 将对象序列化为 XML 文件会引发异常

android - Xamarin中的Build错误缺少youtube软件包

android - 如何在 Xamarin Android 中使用 FontAwesome 图标

c# - Assembly.GetType 返回 null

ios - 'UITableViewCell' 没有名为 'businessLabel' 的成员

jquery - 通过 Jquery 检测用户何时在 iOS 设备上的全屏视频上按 "Done"的事件

ios - 如何在 iOS 中显示 iCarousel 中显示的图像全屏?

c# - 通过函数绑定(bind)文本