Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Question
Monday, July 27, 2015 2:57 PM
I have VS 2013 installed, but it seems broken. That is why I am getting this error when I build my VS C++ Solution that works fine in another computer where VS 2013 is properly installed:
error RC1015: cannot open include file 'afxres.h'.
I have Visual Studio 2013 Ultimate with Update 4 Installed.
When I go to "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\atlmfc\include" the afxres.h is not there, but if i go to "C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\atlmfc\include" or "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\atlmfc\include" the files are there.
I installed every Visual Studio starting with VS 2010 in order up until 2015. I need them for different projects, and I cant just update the solution to use 2015 (I shouldn't have to), I need to make it work with 2013 because my other co-workers are using 2013 and works fine, it works fine in my old computer also.
I have experienced all kind of issues installing 2013, I would have expected Microsoft offered a better experience installing its products. When I thought I finally got 2013 properly installed I installed 2015, but it seems I was wrong, since I cant build yet my solution.
I tried repairing the installation, I tried installing the VS C++ Redistributable(x86), nothing works. How can I make those files be where they ought?
I have tried repairing Visual Studio and I get some warnings saying:
- Microsoft Visual C++ 2012 Core Libraries
This installation is forbidden by system policy. Contact your system administrator
This doesn't make sense, since I have local admin in my computer. Could this be the cause of my issues?
- Note: I am not sure this is the correct forum where to ask this.
All replies (3)
Tuesday, July 28, 2015 12:19 PM âś…Answered | 1 vote
Tina-Shi, Thanks for your answer.
I don't understand what do you mean with:
>>Could you please tell which version of VS you install on one machine in your side?
As I mentioned in my first post I have installed every Visual Studio starting from 2010 up to 2015. Basically I have VS 2010, VS 2012, VS 2013 and VS 2015 installed in my computer. Is that what you were referring to?
Regarding the specific version of VS 2013, you are correct I have VS 2013 Update 4. I tried updating it to the Update 5 but I get some other many errors.
>>First of all, I suggest you could try to TOOLS->Import and Export Settings... Reset all settings check this issue.
I tried resetting the settings. It didn't work. The files are not present in the VC folder, so I was unsure how that could work.
>>And then download and install C++ Redistributable Packages for Visual Studio 2013 to open VS as admin to build C++ project from VS2013 check this issue again.
I tried installing the C++ Redistributable Package for Visual Studio 2013 as you indicated, but it didn't work either.
Previously I've installed en_visual_cpp_redistributable_for_visual_studio_2013_x86_3009067.exe also, but it didn't work either.
>>This installation is forbidden by system policy. Contact your system administrator
I had tried those steps before and they don't work, they don't do anything. Visual Studio should give a more helpful message instead. I have Local Admin in my computer and it is telling to contact my administrator...
I have seen you can get that error installing all kind of different things, so it is not really helpful.
"SOLUTION"
As a final measure I tried copying the VC folder from a computer where VS 2013 is working, and that, for now, has fixed my issues. I call this "SOLUTION", because it is rather ridiculous that it came down to copying the files from another computer, I am not certain whether or not something else is broken somewhere else and is going to blow up in my face later on.
I must say I am rather disappointed with Microsoft on this. It is not unheard of having issues while installing, but so many! And nothing seems to fix them.
Tuesday, July 28, 2015 7:00 AM
Hi Cyllan,
Could you please tell which version of VS you install on one machine in your side?
>>error RC1015:cannot open include file 'afxres.h'.
Since you get the above error message when you build VS C++ solution from this Visual Studio 2013 Ultimate with Update 4.
First of all, I suggest you could try to TOOLS->Import and Export Settings... Reset all settings check this issue.
And then download and install C++ Redistributable Packages for Visual Studio 2013 to open VS as admin to build C++ project from VS2013 check this issue again.
https://www.microsoft.com/en-hk/download/details.aspx?id=40784
In addition, you said that you have tried repairing Visual Studio and I get some warnings saying:
Microsoft Visual C++ 2012 Core Libraries
This installation is forbidden by system policy. Contact your system administrator
About this installation is forbidden by system policy issue, I did some research about it, so please refer the following steps to check this issue.
Click Start -> Control Panel
Open Administrative Tools
Open Local Security Settings
Click Software Restriction Policies
a.If no software restrictions are defined, right click the Software Restriction Policies node and select New Software Restriction Policy
Double click Enforcement
Select "All users except local administrators"
Click OK
Reboot the machineBest Regards,
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click HERE to participate the survey.
Wednesday, July 29, 2015 1:43 AM
Hi Cyllan,
Thanks you share the solution here so that it would be helpful for other members.
Best Regards,
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click HERE to participate the survey.