0
請我有以下問題在Windows Phone 8的設備無法加載插件組裝類型Cheesebaron.MvxPlugins.Settings.PluginLoader
我的包配置運行我的MVVMCross應用是:
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Bulboss.MvvmCross.Plugins.UserInteraction" version="1.3.1" targetFramework="wp8" />
<package id="Cheesebaron.MvxPlugins.Settings" version="2.1.0" targetFramework="wp8" />
<package id="Microsoft.Bcl" version="1.1.9" targetFramework="wp8" />
<package id="Microsoft.Bcl.Build" version="1.0.14" targetFramework="wp8" />
<package id="Microsoft.Net.Http" version="2.2.22" targetFramework="wp8" />
<package id="MvvmCross" version="4.3.0" targetFramework="wp8" />
<package id="MvvmCross.Binding" version="4.3.0" targetFramework="wp8" />
<package id="MvvmCross.Core" version="4.3.0" targetFramework="wp8" />
<package id="MvvmCross.Platform" version="4.3.0" targetFramework="wp8" />
<package id="MvvmCross.Plugin.File" version="4.3.0" targetFramework="wp8" />
<package id="MvvmCross.Plugin.Json" version="4.3.0" targetFramework="wp8" />
<package id="MvvmCross.Plugin.Location" version="4.3.0" targetFramework="wp8" />
<package id="MvvmCross.Plugin.Messenger" version="4.3.0" targetFramework="wp8" />
<package id="MvvmCross.Plugin.Network" version="4.3.0" targetFramework="wp8" />
<package id="MvvmCross.Plugin.Visibility" version="4.3.0" targetFramework="wp8" />
<package id="MvvmCross.StarterPack" version="4.3.0" targetFramework="wp8" />
<package id="Newtonsoft.Json" version="9.0.1" targetFramework="wp8" />
<package id="WPtoolkit" version="4.2013.08.16" targetFramework="wp8" />
</packages>
我有插件自舉如下
public class SettingsPluginBootstrap : MvxPluginBootstrapAction<Cheesebaron.MvxPlugins.Settings.PluginLoader>
{
}
,而且我用插件的設置,像這樣
public class SettingsService
{
private ISettings _settings;
public SettingsService(ISettings settingsService)
{
_settings = settingsService;
}
}
我的Windows Phone應用程序構造器的設置如下
public App()
{
var setup = new Setup(RootFrame);
setup.Initialize();
}
但每當setup.Initialize()被調用。我得到以下異常
Additional information: could not load plugin assembly for type Cheesebaron.MvxPlugins.Settings.PluginLoader
at MvvmCross.Platform.Plugins.MvxFilePluginManager.LoadAssembly(Type toLoad)
at MvvmCross.Platform.Plugins.MvxFilePluginManager.FindPlugin(Type toLoad)
at MvvmCross.Platform.Plugins.MvxPluginManager.ExceptionWrappedLoadPlugin(Type toLoad)
at MvvmCross.Platform.Plugins.MvxPluginManager.EnsurePlatformAdaptionLoaded[T]()
at Cheesebaron.MvxPlugins.Settings.PluginLoader.EnsureLoaded()
at MvvmCross.Platform.Plugins.MvxPluginManager.EnsurePluginLoaded(IMvxPluginLoader pluginLoader)
at MvvmCross.Platform.Plugins.MvxPluginManager.EnsurePluginLoaded(Type type)
at MvvmCross.Platform.Plugins.MvxPluginManager.EnsurePluginLoaded[TType]()
at MvvmCross.Platform.Plugins.MvxPluginBootstrapAction`1.Load(IMvxPluginManager manager)
at MvvmCross.Platform.Plugins.MvxPluginBootstrapAction`1.RunAction()
at System.Action.Invoke()
at MvvmCross.Platform.IoC.MvxSimpleIoCContainer.InternalSetResolver(Type tInterface, IResolver resolver)
at MvvmCross.Platform.IoC.MvxSimpleIoCContainer.RegisterSingleton[TInterface](TInterface theObject)
at MvvmCross.Platform.Mvx.RegisterSingleton[TInterface](TInterface service)
at MvvmCross.Core.Platform.MvxSetup.InitializePluginFramework()
at MvvmCross.Core.Platform.MvxSetup.InitializeSecondary()
at MvvmCross.Core.Platform.MvxSetup.Initialize()
at IGovern.WinPhone.App..ctor()
請問我在做什麼錯?
你的目標是Windows Phone 8.0 Silverlight。它不受支持。 – Cheesebaron