Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.7k views
in Technique[技术] by (71.8m points)

visual studio 2010 - VS2010 command prompt gives error: Cannot determine the location of the VS Common Tools folder

I have installed VS2010. The installation creates the shortcut for VS2010 command prompt but when I open up the command prompt I get the error:

Cannot determine the location of the VS Common Tools folder.

I checked the environment variable VS100COMNTOOLS and it has value: C:Program FilesMicrosoft Visual Studio 10.0Common7Tools and the registry for HKEY_local_MachineSoftwareMicrosoftVisual StudioSxSVS7 is set to: C:Program FilesMicrosoft Visual Studio 10.0.

I checked the VSvars32.bat and tried to add echo to find till where it proceeds. It fails at this command:

@call :GetVSCommonToolsDirHelper32 HKLM > nul 2>&1
See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

I had the same issue and found the answer here.

The problem is that the bat uses de reg command and it searches that in the PATH system variable. Somehow you have managed to get "C:WindowsSystem32" out of the PATH variable, so just go to the system variables (right click "My Computer" > "Properties" > advanced config > "Environment Variables", search the PATH variable and add at the end separated by ";" : C:WindowsSystem32


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...