I like to create platform independent apps for Win/Mac/Linux, Android and so on but the platform I have most problems with (except iOS) is UWP...
So now I want to load a external project, a Window Runtime Component-dll, when I have the component as a project in the same solution in visual studio it works fine.
When I build the component outside visual studio and referencing it to my project I get this error when I call a class stored in the runtime component:
System.TypeLoadException: 'Requested Windows Runtime type 'SharpDepend_UWP_DirectXInterop.D3DPanel' is not registered.' Inner Exception COMException: Klassen har inte registrerats (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG))
I have these projects:
And the SharpDepend projets is my external dlls, and they are stored in a Binaries-folder with all output generated files, dll and winmd.
Everything compiles but I get the error when the first class in loading in the DirectXInterop projects.
Is there anyone who is expert in UWP and know the problem? :)
My problem was that the component DLL and Winmd files did not had the same name. My component was named with a '.' char and when Visual Studio compile the Winmd replaces the '.' to an '_' but didnt do that for the DLL file.
Note: After that I also had to manually copy some files from the component project to my App-project: SimplePixelShader.cso and SimpleVertexShader.cso. Otherwise my app didnt found them and they seems to not be baked in the dll or winmd file.
User contributions licensed under CC BY-SA 3.0