Xamarin.ios 在MonoTouch/VSMonoTouch中键入ForwardedTo拒绝为System.Windows.Input.ICommand工作
我已经实现了相当多的Xamarin.ios 在MonoTouch/VSMonoTouch中键入ForwardedTo拒绝为System.Windows.Input.ICommand工作,xamarin.ios,portable-class-library,Xamarin.ios,Portable Class Library,我已经实现了相当多的TypeForwardedTo路由,使用了来自 但是,我现在尝试将TypeForwardTo(System.Windows.Input.ICommand)添加到列表中,由于某种原因,该类型拒绝工作 基本上,我得到的错误信息是: 错误5命名空间“System”中不存在类型或命名空间名称“Windows”(是否缺少程序集引用?) 我不明白为什么当我在Reflector中查看System.dll的VSMonoTouch副本时,我可以清楚地看到ICommand类型: .namespa
TypeForwardedTo
路由,使用了来自
但是,我现在尝试将TypeForwardTo(System.Windows.Input.ICommand)添加到列表中,由于某种原因,该类型拒绝工作
基本上,我得到的错误信息是:
错误5命名空间“System”中不存在类型或命名空间名称“Windows”(是否缺少程序集引用?)
我不明白为什么当我在Reflector中查看System.dll的VSMonoTouch副本时,我可以清楚地看到ICommand类型:
.namespace System.Windows.Input
{
.class public interface abstract auto ansi ICommand
{
.event [mscorlib]System.EventHandler CanExecuteChanged
{
.addon instance void System.Windows.Input.ICommand::add_CanExecuteChanged(class [mscorlib]System.EventHandler)
.removeon instance void System.Windows.Input.ICommand::remove_CanExecuteChanged(class [mscorlib]System.EventHandler)
}
.method public hidebysig newslot abstract virtual instance bool CanExecute(object parameter) cil managed
{
}
.method public hidebysig newslot abstract virtual instance void Execute(object parameter) cil managed
{
}
}
}
System.dll中的其他类型转发正常-即,只有最后一行在以下方面失败:
[assembly: TypeForwardedTo(typeof(System.Collections.ObjectModel.ObservableCollection<>))]
[assembly: TypeForwardedTo(typeof(System.Collections.ObjectModel.ReadOnlyObservableCollection<>))]
[assembly: TypeForwardedTo(typeof(System.Collections.Specialized.INotifyCollectionChanged))]
[assembly: TypeForwardedTo(typeof(System.Collections.Specialized.NotifyCollectionChangedAction))]
[assembly: TypeForwardedTo(typeof(System.Collections.Specialized.NotifyCollectionChangedEventArgs))]
[assembly: TypeForwardedTo(typeof(System.Collections.Specialized.NotifyCollectionChangedEventHandler))]
[assembly: TypeForwardedTo(typeof(System.Windows.Input.ICommand))]
[程序集:TypeForwardedTo(typeof(System.Collections.ObjectModel.ObservableCollection))]
[程序集:TypeForwardedTo(typeof(System.Collections.ObjectModel.ReadOnlyObservableCollection))]
[程序集:TypeForwardedTo(typeof(System.Collections.Specialized.INotifyCollectionChanged))]
[程序集:TypeForwardedTo(typeof(System.Collections.Specialized.NotifyCollectionChangedAction))]
[程序集:TypeForwardedTo(typeof(System.Collections.Specialized.NotifyCollectionChangedEventArgs))]
[程序集:TypeForwardedTo(typeof(System.Collections.Specialized.NotifyCollectionChangedEventHandler))]
[程序集:TypeForwardedTo(typeof(System.Windows.Input.ICommand))]
此外:
-我知道这个机器人的重定向工作正常。。。。
-我知道System.Windows.Input.ICommand是最近添加到MonoTouch的
-我怀疑VSMonoTouch使用.Net Framework版本的1.0可能也会导致一些问题(但我不确定我是否完全理解这一点)
有人能提出这可能是什么原因吗?那么什么是治疗方法呢