Error CS1056: Unexpected character ‘$’ running the msbuild on a tfs continuous integration process

The problem can be fixed installing a Nuget package Microsoft.Net.Compilers. Below is the link of my highlighted answer: Project builds fine with Visual Studio but fails from the command line That feature is a syntactic sugar for C#6, try to install the latest version of the framework 4.6.2 https://www.microsoft.com/en-us/download/details.aspx?id=53345 Then go to your Project properties … Read more

Copy all dependencies from .Net Standard libraries to .Net Framework Console application

After going through an article by Scott Hanselman, below solution worked like a charm. “Using .NET Standard requires you to use PackageReference to eliminate the pain of “lots of packages” as well as properly handle transitive dependencies. While you may be able to use .NET Standard without PackageReference, I wouldn’t recommend it.” Add below line … Read more

You must add a reference to assembly ‘netstandard, Version=2.0.0.0

I think the solution might be this issue on GitHub: Try add netstandard reference in web.config like this:” <system.web> <compilation debug=”true” targetFramework=”4.7.1″ > <assemblies> <add assembly=”netstandard, Version=2.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51″/> </assemblies> </compilation> <httpRuntime targetFramework=”4.7.1″ /> I realise you’re using 4.6.1 but the choice of .NET 4.7.1 is significant as older Framework versions are not fully compatible … Read more

Determine .NET Framework version for dll

In PowerShell you can use the following to get the target runtime: $path = “C:\Some.dll” [Reflection.Assembly]::ReflectionOnlyLoadFrom($path).ImageRuntimeVersion I adapted this to PowerShell from Ben Griswold’s answer. If you want to know the target framework version specified in Visual Studio, use: $path = “C:\Some.dll” [Reflection.Assembly]::ReflectionOnlyLoadFrom($path).CustomAttributes | Where-Object {$_.AttributeType.Name -eq “TargetFrameworkAttribute” } | Select-Object -ExpandProperty ConstructorArguments | Select-Object … Read more