Win7-64 bit. Visual Studio 2015 Community Edition
I am unable to get MMA to recognise the VS Compiler to compile functions to C.
I had installed VS Studio and the C++ compiler (and test compiled the calculator demo); I reinstalled .NET Framework 4.6.1 afterwards and let it make any repairs necessary.
I have followed the instructions in the answer to question 41682 and in the community group, i.e. I have edited VisualStudioCompiler.m to add "2015" to the versions and the installpath reference to, so those lines now read CORRECTION changed {"2015","..} to {"2015", "...} in .m file - made no difference.
$VisualStudioVersions = {"2015","2013", "2012", "2010", "2008", "2005"}
and CORRECTION^2 changed "InstallPath" to "installPath" in .m file - FIXED IT.
installPath["2015"] := installPathFromEnvironment["VS140COMNTOOLS"]
The file was saved to the desktop and copied back to the MMA folder successfully.
I have checked the environment variable in Control Panel -> System -> Advanced -> Environment Variables and there is a variable VS140COMNTOOLS with the value "C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\Tools\"
I quit and restarted MMA but after executing
Needs["CCompilerDriver`"]
CCompilers[Full]
MMA still can't find the compiler; I still get as output
{{"Name" -> "Intel Compiler",
"Compiler" -> CCompilerDriver`IntelCompiler`IntelCompiler,
"CompilerInstallation" -> None,
"CompilerName" -> Automatic}, {"Name" -> "Generic C Compiler",
"Compiler" -> CCompilerDriver`GenericCCompiler`GenericCCompiler,
"CompilerInstallation" -> None, "CompilerName" -> Automatic}}
VS Studio was "registered" (So removing the "trial" period of free use).
I have also just restared the whole PC and CCompilers[Full] returns the same result.
Is anyone able to offer further advice?