Download

[HELP] Failed to generate code project files for... with VisualStudio 2013 express

I have Visual Studio 2013 Express installed in my system…and no other Visual studio tools was ever installed in it. However when I try to create a new code project using Project Wizard, I get the error Failed to generate code project files for…xxyyzz.uproject.

I tried editing the VSAccessor.Build.cs file as some of the threads suggested. But it id not work for me. SO what do I do?

Any idea how to fix it. I have searched unreal answers hub and tried different methods, but none of them works.

PS: I installed UE4 first and Visual studio later

With Windows 8 and VS Express 2013 i too had a lot of problems. I fixed most of them by slightly changing the source code and by running Unreal Editor and VS Express 2013 as Administrator. Now since my monitor is dead, am now working on my brothers PC which is Windows 7 and VS Professional 2013. Works like a charm…no issues at all.

But anyway to make it generate project files i modified the VCToolChain.cs located in Installation Directory\Engine\Source\Programs\UnrealBuildTool\Windows\VCToolChain.cs
In VCToolChain.cs at line 1503, i changed it to:
var VS2013Path = “D:\Microsoft Visual Studio 12.0\Common7\Tools\”;

Then in Installation Directory\Engine\Source\Developer\Windows\VSAccessor\Private\VSAccessorModule.cpp i modified at line number 748 to this:
FString BaseExecutablePath = D:\Microsoft Visual Studio 12.0\Common7\Tools\;

After these changes i had no problems of generating project files or opening them. Only problem i had was compiling from the editor. I had no problems compiling using Visual Studio.

I posted this on AnswerHub with more detailed information and pictures. Please check it out: https://answers.unrealengine.com/questions/21153/unreal-fails-to-read-environment-variable-and-fail.html

Thanks. I will try this out. So are they hard-coding the visual studio path into the code files? Thats terrible. Couldn’t they retrieve it from the environment variables.

I believe this is the issue for me, because My visual studio is installed in E: drive (not in OS drive).

I will update this thread soon