Open WJMBZM opened 9 months ago
This wrong is "Unhandled exception: System. I0. FileNotFound Exception: Could not load file or assembly 'System. Runtime, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the specified file."
How exactly are you starting your process? The new version uses .NET 6.0 and therefore might need a change in how you start the application.
Yeah,I find it,the previous version uses .Net Framework 4.8, and this new version use .Net core 6.0.So this may be the problem that I meet.
This Image shows what mode I can choose.
There are 3 usual mode (there is no CLR || .Net runtime support(clr/.net:core) || .Net Framework runtime support(clr)).
I use CLR(Common language runtime support) so that I can use this C# DLL(dynamic link lib) in C++\CLI platform(visual studio),It seems that .Net Core cant use C# DLL ,or I should use some other methods.
I try to change .Net Core to .Net Framework,or I try to find another way to use C# DLL in C++\CLI platform with .Net Core.
I'm the beginner of C#,It's so sorry to bother u so much.
/* And I have another question,It's how to get the family or model of CPUs.
I can find "AlderLake" of 12th generation CPU,"RaptorLake" of 13th generation CPU .But the code of CPU family(model),like 0x97(Intel Core 12th in PC),0x9A(Intel Core 12th in Mobile),0xB7\0XBA(Intel Core 13th).
How should I get this.(when 14th 15th......appear) */
I have found the mothod of getting family and model.- o -`
Thanks for ur help.
Yea, you need to use the /clr:netcore setting, and then (in one of the other dropdown boxes) select .NET 6.0. You might need to close and reopen the dialog to get the correct list of options there.
About your other questions: We don't know. We need to wait until the new CPUs come out and then add the new family IDs.
Does C++/CLI even exist for .NET Core?
@mcendu Yes, C++/CLI support is still available in .NET 6.0 and above. It looks like it's not getting that much attention, so things may get a bit ugly (e.g. referencing other C# libraries may need a bit of trickery), but if you just need it as a wrapper for an unmanaged library, it still works.