C# MVVMCross更新错误:不包含';以'结尾;没有扩展方法';以'结尾;
我正在使用Visual Studio 2013开发Windows通用应用程序 我刚刚通过nuget和App.cs在我的解决方案中升级了MVVMCross,使用以下方法可以毫无问题地工作C# MVVMCross更新错误:不包含';以'结尾;没有扩展方法';以'结尾;,c#,cross-platform,mvvmcross,C#,Cross Platform,Mvvmcross,我正在使用Visual Studio 2013开发Windows通用应用程序 我刚刚通过nuget和App.cs在我的解决方案中升级了MVVMCross,使用以下方法可以毫无问题地工作 public class App : MvxApplication { public override void Initialize() { CreatableTypes() .EndingWith("Service") .As
public class App : MvxApplication
{
public override void Initialize()
{
CreatableTypes()
.EndingWith("Service")
.AsInterfaces()
.RegisterAsLazySingleton();
RegisterAppStart<ViewModels.StartViewModel>();
}
}
公共类应用程序:MVX应用程序
{
公共覆盖无效初始化()
{
createabletypes()
.以“服务”结尾
.a接口()
.registeraslazyingleton();
RegisterAppStart();
}
}
但是在升级之后,我得到了以下错误
Error 2 'System.Collections.Generic.IEnumerable<System.Type>' does not contain a definition for 'EndingWith' and no extension method 'EndingWith' accepting a first argument of type 'System.Collections.Generic.IEnumerable<System.Type>' could be found (are you missing a using directive or an assembly reference?) D:\Users\Vicky\OneDrive\Dev\WUA\KpopQuiz.Core\KpopQuiz.Core\App.cs 11 18 KpopQuiz.Core
错误2“System.Collections.Generic.IEnumerable”不包含“EndingWith”的定义,并且找不到扩展方法“EndingWith”接受类型为“System.Collections.Generic.IEnumerable”的第一个参数(是否缺少using指令或程序集引用?)D:\Users\Vicky\OneDrive\Dev\WUA\kpopquick.Core\kpopquick.Core\App.cs 11 18 kpopquick.Core
是否以
结尾,或者是否有新的方法初始化服务
类?您只需使用MvvmCross.Platform.IoC添加一个引用即可
来使用它。您只需使用MvvmCross.Platform.IoC添加一个带有的引用代码>以使用它