I have a class library which uses CSVHelper
(v19.0.0). I installed CSVHelper
via Nuget in VS2019 (Version 16.5.5; .NET 4.8.03752), and can confirm that the package is where it 'should' be (based on checking my project/dependencies/package/CSVHelper/properties, which shows C:Users[my_name].nugetpackagescsvhelper19.0.0
). [EDIT: I have checked my [solution name].csproj file and see that contains PackageReference Include="CsvHelper" Version="19.0.0"
]
However, when I try to call one of the methods in my class library, I get the error message shown below.
I have Googled this and others encountered the same problem with earlier versions of CSVHelper (e.g. https://github.com/JoshClose/CsvHelper/issues/944) but their solutions have not worked for me. I have tried: 1) cleaning and rebuilding the solution; 2) removing CSVHelper then reinstalling via Nuget; and 3) removing all old versions of CSVHelper from the .nuget folder on my C drive. The problem continues to appear. Help would be much appreciated.
System.IO.FileNotFoundException
HResult=0x80070002
Message=Could not load file or assembly 'CsvHelper, Version=19.0.0.0, Culture=neutral, PublicKeyToken=8c4959082be5c823' or one of its dependencies. The system cannot find the file specified.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…