Based on the question Compile string as code includes in my project the ScriptEngine
class, however, it is not being found in the references:
using Microsoft.CodeAnalysis.Scripting;
using Microsoft.CodeAnalysis.Scripting.CSharp; //Nesta
Installing with NuGet Packages for Solution I searched for Microsoft.CodeAnalysis.Scripting
and installed it, but did not install the next ( Microsoft.CodeAnalysis.Scripting.CSharp
) for incompatibility.
I can install the reference Microsoft.CodeAnalysis.Scripting.CSharp
by the console with the commands (in order in the console):
PM > Install-Package Microsoft.DiaSymReader.Native
PM > Install-Package Microsoft.CodeAnalysis.Scripting.CSharp -Pre
But in this way ScriptEngine
is not being found.
What do I do to use ScriptEngine
?