Prism V8 and Visual Studio Installer Project issue #2470
Unanswered
Shannon-roos
asked this question in
WPF
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi All,
I'm looking for some guidance on an issue regarding Prism v8 WPF (8.1.97 currently).
If I create a blank prism WPF Application using the template and run via VS 2019 it works just fine.
If I then add a Visual Studio Installer Project and add the primary output of the "Main" project to it and try to install and Run the now packaged app I get the following error in EventViewer...
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.BadImageFormatException
Exception Info: System.BadImageFormatException
at Unity.Builder.BuilderContext.Resolve(System.Type, System.String, Unity.Registration.InternalRegistration)
at Unity.Builder.BuilderContext.Resolve(System.Type, System.String)
at Unity.Builder.BuilderContext.Resolve(System.Reflection.ParameterInfo, System.Object)
at Unity.Processors.ConstructorProcessor+<>c__DisplayClass16_0.b__0(Unity.Builder.BuilderContext ByRef)
at Unity.Processors.MemberProcessor
2+<>c__DisplayClass8_0[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].<GetResolver>b__0(Unity.Builder.BuilderContext ByRef) at Unity.Processors.MemberProcessor
2+<>c__DisplayClass8_0[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].b__0(Unity.Builder.BuilderContext ByRef)at Unity.Processors.MemberProcessor
2+<>c__DisplayClass8_0[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].<GetResolver>b__0(Unity.Builder.BuilderContext ByRef) at Unity.Strategies.BuildPlanStrategy.PreBuildUp(Unity.Builder.BuilderContext ByRef) at Unity.UnityContainer+<>c.<.ctor>b__73_1(Unity.Builder.BuilderContext ByRef) at Unity.UnityContainer.Unity.IUnityContainer.Resolve(System.Type, System.String, Unity.Resolution.ResolverOverride[]) at Prism.Unity.UnityContainerExtension.Resolve(System.Type, System.ValueTuple
2<System.Type,System.Object>[])Exception Info: Prism.Ioc.ContainerResolutionException
at Prism.Unity.UnityContainerExtension.Resolve(System.Type, System.ValueTuple`2<System.Type,System.Object>[])
at Prism.Ioc.IContainerProviderExtensions.Resolve[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]
at Prism.Regions.RegionAdapterMappings.RegisterMapping[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]
at Prism.PrismInitializationExtensions.RegisterDefaultRegionAdapterMappings(Prism.Regions.RegionAdapterMappings)
at Prism.PrismApplicationBase.ConfigureRegionAdapterMappings(Prism.Regions.RegionAdapterMappings)
at Prism.PrismApplicationBase.Initialize()
at Prism.PrismApplicationBase.InitializeInternal()
at System.Windows.Application.<.ctor>b__1_0(System.Object)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
at System.Windows.Threading.DispatcherOperation.InvokeImpl()
at MS.Internal.CulturePreservingExecutionContext.CallbackWrapper(System.Object)
at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
at MS.Internal.CulturePreservingExecutionContext.Run(MS.Internal.CulturePreservingExecutionContext, System.Threading.ContextCallback, System.Object)
at System.Windows.Threading.DispatcherOperation.Invoke()
at System.Windows.Threading.Dispatcher.ProcessQueue()
at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
at MS.Win32.HwndWrapper.WndProc(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(System.Object)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(System.Windows.Threading.DispatcherPriority, System.TimeSpan, System.Delegate, System.Object, Int32)
at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr, Int32, IntPtr, IntPtr)
at MS.Win32.UnsafeNativeMethods.DispatchMessage(System.Windows.Interop.MSG ByRef)
at System.Windows.Threading.Dispatcher.PushFrameImpl(System.Windows.Threading.DispatcherFrame)
at System.Windows.Application.RunDispatcher(System.Object)
at System.Windows.Application.RunInternal(System.Windows.Window)
at Main.App.Main()
I have my project set to x64 as well as the install project. There is another Stackoverflow question with the same issue without a resolution so I'm looking for some understaning of what I can do to troubleshoot this further?
If I "downgrade" the NuGet packages to V7 (7.0.0.362 from NuGet) and rebuild the project and Setup then the app will install and load the Main Window just fine.
Any help\advice would be an insane help as I'm lost for exactly what the issue could be...
Cheers,
Shannon
Beta Was this translation helpful? Give feedback.
All reactions