Compiler executable file vbc.exe cannot be found
I am facing the following error in my VB.NET web app:
开发者_StackOverflow中文版compiler executable file vbc.exe cannot be found.
I installed .net framework again and even the IDE, but this error remains. Please help.
I've just run into this myself while play with the CodeDom. If you are manually setting the version you probably have a some code that looks like:
Dim providerOptions = New Collections.Generic.Dictionary(Of String, String)
providerOptions.Add("CompilerVersion", "v4.0")
Dim provider As New VBCodeProvider(providerOptions)
If you forget the "v" and have "4.0" as the value in your dictionary item, you will get this error.
I'd guess that you're missing a path to it or something like that. Try going to look in the [Your Windows Dir]\Microsoft.NET\Framework
and go into the sub folders there and see if there isn't a vbc.exe.
Try installing the .NET Framework v3.5 Feature if you are on Windows Server 2008 R2. Otherwise, try installing .NET Framework v3.5.
I solved it like this:
Go to Control Panel -> Programs and Features
Click: Turn Windows features on or off
Un-check the box ".NET Framework 4.6 Advanced Services"
Check ".NET Framework 3.5 (includes .NET 2.0 and 3.0)"
Click: OK
Reinstall you software if needed..
Just apply windows hotfixes KB 951708 and KB 953595 to fix your problem.
More details:
http://support.microsoft.com/kb/832597
精彩评论