skip to Main Content

I’m working on an application where I can get the CPU and GPU temperature. I followed the steps here (http://www.lattepanda.com/topic-f11t3004.html ) while developing the application, but I’m using VS Code and I couldn’t add the OpenHardwareMonitorLib.dll file as a reference like in Visual Studio. I’m not so sure how I should add the dll file to the project. I would be glad if you help. Here is my project files;

enter image description here

2

Answers


  1. Don’t know way to do this with VSCode, but…

    Not every tool is good for everything. I’ll try use Visual Studio 2022 Community to add this DLL. It should make changes to the project, which are independent of the editor you are using. Or do it manually like @hotdog_buns said. I hope it works.

    Login or Signup to reply.
  2. You need to add a reference to any .dll files in your csTemp.csproj file as such:

      <ItemGroup>
         <Reference Include="OpenHardwareMonitorLib">
          <HintPath>**pathtoyourdll**</HintPath>
         </Reference>
      </ItemGroup>
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search