Using NuGet packages on Microsoft Visual Studio

Alan 0 Reputation points
2023-05-24T23:09:42.62+00:00

I have been trying for 5 days to use a NuGet package on microsoft visual studio. I have watched a bunch of videos and read articles and it looks like you just need to download and update the package from NuGet package manager and then use it. Every time I do this, I get CSO246 errors telling me I'm missing a reference. When I hit add reference it always shows that I have no references. Please help

Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
5,277 questions
Visual Studio Extensions
Visual Studio Extensions
Visual Studio: A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.Extensions: A program or program module that adds functionality to or extends the effectiveness of a program.
234 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Tianyu Sun-MSFT 31,696 Reputation points Microsoft Vendor
    2023-05-25T02:33:15.07+00:00

    Hello @Alan,

    Welcome to Microsoft Q&A forum.

    If you have the NuGet package installed, you may find it lists here(for example, .NET 7.0 based, C# project):

    User's image

    For CSO246 error, can you confirm that you have added using XXXX;, for example:

    User's image

    If you added using XXXX, but still don't work, please share us some screenshots and detailed steps to reproduce this issue and check further.

    Looking forward to hearing from you.

    Sincerely,

    Tianyu


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.