Hi,
I am developing a protocol that uses the Microsoft.Management.Infrastructure Nuget package. When the element runs it complains about missing an assembly reference.
On the DMA where the prototol was published, I could not find the Microsoft.Management.Infrastructure DLL file anywhere within the "Skyline DataMiner" folder.
To troubleshoot, in Visual Studio I "Save compiled protocol" as a .dmprotocol file. I then looked within the .dmprotocol file and could not find any Microsoft.Management.Infrastructure DLL file.
Are there any steps I have missed?
Thanks,
Trong.
Hi,
There are some limitations on the NuGet packages that are currently supported by DIS (see also Consuming NuGet packages):
- DIS currently only processes the lib folder of NuGet packages. Other folders such as ref or runtimes are currently not supported.
The items contained in the Microsoft.Management.Infrastructure NuGet packageare under the ref folder (as can be seen here) and the items contained in the Microsoft.Management.Infrastructure.Runtime.Win NuGet package are under the runtimes folder (as can be seen here).
What you could try is to extract the required assemblies from the NuGet package and put it under the Dlls folder of your connector solution.
Thanks, Pedro. That makes sense. I couldn't get the workaround to work (i.e. copying the runtime to the Solution DLL folder). I ended up using an alternative NuGet library that works.