WasmWinforms
WasmWinforms copied to clipboard
Unhandled Mono AssemblyResolutionException
Hi there,
I am attempting to build my application and getting the following error with the complete app not being outputted into the dist folder:
Unhandled Exception: Mono.Cecil.AssemblyResolutionException: Failed to resolve assembly: 'System.Windows.Forms, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'
at Mono.Cecil.BaseAssemblyResolver.Resolve(AssemblyNameReference name, ReaderParameters parameters)
at Driver.Import(String ra, AssemblyKind kind)
at Driver.Run(String[] args)
at Driver.Main(String[] args)
WasmForm C:\Users\myuser\.nuget\packages\winforms.wasm\1.0.19137.60\build\netstandard2.0\Winforms.Wasm.targets 13
This is using version 1.0.19137.60 and .NET Core 2.1. If there is any additional information I can provide please let me know.
Same Issue here
Does the samples work for you? I retested it and it seems to be working fine...
Workaround in csproj:
<CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies>
Hi
While adding the <CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies> got me passed the 'cant resolve assembly: 'System.Windows.Forms' I simply came to another unhandled exception: 13,5): error : Unhandled Exception: Mono.Cecil.AssemblyResolutionException: Failed to resolve assembly: 'System.Formats.Asn1, Version=5.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' 1> C:\Users\howar_000.nuget\packages\winforms.wasm\1.0.19137.60\build\netstandard2.0\Winforms.Wasm.targets(13,5): error : at Mono.Cecil.BaseAssemblyResolver.Resolve(AssemblyNameReference name, ReaderParameters parameters) 1> C:\Users\howar_000.nuget\packages\winforms.wasm\1.0.19137.60\build\netstandard2.0\Winforms.Wasm.targets(13,5): error : at Driver.Import(String ra, AssemblyKind kind) 1> C:\Users\howar_000.nuget\packages\winforms.wasm\1.0.19137.60\build\netstandard2.0\Winforms.Wasm.targets(13,5): error : at Driver.Import(String ra, AssemblyKind kind) 1> C:\Users\howar_000.nuget\packages\winforms.wasm\1.0.19137.60\build\netstandard2.0\Winforms.Wasm.targets(13,5): error : at Driver.Import(String ra, AssemblyKind kind) 1> C:\Users\howar_000.nuget\packages\winforms.wasm\1.0.19137.60\build\netstandard2.0\Winforms.Wasm.targets(13,5): error : at Driver.Import(String ra, AssemblyKind kind) 1> C:\Users\howar_000.nuget\packages\winforms.wasm\1.0.19137.60\build\netstandard2.0\Winforms.Wasm.targets(13,5): error : at Driver.Run(String[] args) 1> C:\Users\howar_000.nuget\packages\winforms.wasm\1.0.19137.60\build\netstandard2.0\Winforms.Wasm.targets(13,5): error : at Driver.Main(String[] args) 1> C:\Users\howar_000.nuget\packages\winforms.wasm\1.0.19137.60\build\netstandard2.0\Winforms.Wasm.targets(13,5): error : 1> -----BuildWasm Ended Successfully------ 1> Done executing task "BuildWasmTask" -- FAILED.
Any idea how to get past this problem? Howard