Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VPC error: "Unable to find RegKey for .vcproj files in solutions" #72

Closed
Artfunkel opened this issue Jul 5, 2013 · 36 comments
Closed

Comments

@Artfunkel
Copy link

I get this when running creategameprojects.bat:

C:\valve\source2013\mp\src>devtools\bin\vpc.exe /hl2mp +game /mksln games.sln
VPC - Valve Project Creator For Visual Studio, Xbox 360, PlayStation 3 (Build: Jun  5 2013 15:27:08)
(C) Copyright 1996-2010, Valve Corporation, All rights reserved.

Source Path: C:\valve\source2013\mp\src
Target Platform: win32
Generating for Visual Studio 2010.

Valid: 'client_hl2mp.vcxproj' Passes CRC Checks.

Valid: 'mathlib.vcxproj' Passes CRC Checks.

Valid: 'server_hl2mp.vcxproj' Passes CRC Checks.

Valid: 'tier1.vcxproj' Passes CRC Checks.

Valid: 'vgui_controls.vcxproj' Passes CRC Checks.

Building partial dependency set (libs only)........


Writing solution file C:\valve\source2013\mp\src\games.sln.

ERROR: Unable to find RegKey for .vcproj files in solutions.

I have these VS products installed:

  • Visual C++ Express 2010
  • Visual C# Express 2010
  • Visual Studio Express 2013 Preview

...all of which are from the vcxproj era, so it's not surprising that vcproj isn't in my registry.

@benpye
Copy link

benpye commented Jul 5, 2013

May it be related to the fact it's C++ Express, I have VS2010, VS2012, and VS2013 preview installed and do not get this error. They are all professional or above.

@bruced-valve
Copy link
Contributor

In my registry it has a DefaultProjectExtension string with a value of vcproj in:
HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\10.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}

In that same key it has a PossibleProjectExtensions string that contains .vcxproj. So, it appears that even in VS 2010 and above they publicly declare that vcproj is the default extension.

Can you look in the registry for DefaultProjectExtension and see what you find?

From: ben1066 [mailto:notifications@github.com]
Sent: Friday, July 05, 2013 6:59 AM
To: ValveSoftware/source-sdk-2013
Subject: Re: [source-sdk-2013] VPC error: "Unable to find RegKey for .vcproj files in solutions" (#72)

May it be related to the fact it's C++ Express, I have VS2010, VS2012, and VS2013 preview installed and do not get this error. They are all professional or above.


Reply to this email directly or view it on GitHubhttps://github.com//issues/72#issuecomment-20520167.

@joeangry
Copy link

joeangry commented Jul 5, 2013

I have VS2010 Express and VS2012 Pro installed. The key \10.0_Config\ key doesn't exist. However VS2012 got the key but in HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\11.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942} (notice 11.0_Config) instead.

I get the same error as Artfunkel.

@bruced-valve
Copy link
Contributor

If there is no 10.0_Config key then that's a big problem for people who only have 2010 Express installed. We could hard-code the GUID but I'm not sure if that is the correct fix.

In the 11.0_Config key is there a DefaultProjectExtension of vcxproj or vcproj? My 11.0_Config install has a vcxproj DefaultProjectExtension.

@joeangry
Copy link

joeangry commented Jul 5, 2013

Yes there is one for vcxproj. It's located at

HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\11.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}

The only difference being the version number for VS2012.

@bruced-valve
Copy link
Contributor

Okay, good to know. Can you check in these two locations for a DefaultProjectExtension of vcxproj or vcproj:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\10.0\Projects

and:

HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\VisualStudio\10.0\Projects

My reg address using HKEY_CURRENT_USERS is incorrect. If I can find out what VC++ 2010 Express stores then I can do the correct fix.

@joeangry
Copy link

joeangry commented Jul 5, 2013

No luck.

However this contains "DefaultProjectExtension" and "PossibleProjectExtensions" values "vcproj" and "vcxproj;vcproj;dsp;mdp;mak;vcp;nativeproj" respectively
HKEY_CURRENT_USER\Software\Microsoft\VCExpress\10.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}

@Artfunkel
Copy link
Author

I have these:

[HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\10.0_Config\Projects\{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}]
"Package"="{F1C25864-3097-11D2-A5C5-00C04F7968B4}"
"DisplayProjectFileExtensions"="#10003"
"DefaultProjectExtension"="vcproj"
"PossibleProjectExtensions"="vcxproj;vcproj;dsp;mdp;mak;vcp;nativeproj"
"ProjectTemplatesDir"="c:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\.\\VCProjects"
"ItemTemplatesDir"="c:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\.\\VCProjectItems"
"DesignerTemplatesDir"="c:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\.\\DesignerTemplates"
"DevStudioPackageID"=dword:00000004
"ResourcesFolderBehavior"=dword:00000002
"DisableOnlineTemplates"=dword:00000001
@="#10006"

[HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\VCExpress\10.0\Projects\{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}]
"Package"="{F1C25864-3097-11D2-A5C5-00C04F7968B4}"
"DisplayProjectFileExtensions"="#10003"
"DefaultProjectExtension"="vcproj"
"PossibleProjectExtensions"="vcxproj;vcproj;dsp;mdp;mak;vcp;nativeproj"
"ProjectTemplatesDir"="c:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\Express\\VCProjects"
"ItemTemplatesDir"="c:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\Express\\VCProjectItems"
"DesignerTemplatesDir"="c:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\Express\\DesignerTemplates"
"DevStudioPackageID"=dword:00000004
"ResourcesFolderBehavior"=dword:00000002
"DisableOnlineTemplates"=dword:00000001
@="#10006"

[HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\10.0_Config\Projects\{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}]
"Package"="{F1C25864-3097-11D2-A5C5-00C04F7968B4}"
"DisplayProjectFileExtensions"="#10003"
"DefaultProjectExtension"="vcproj"
"PossibleProjectExtensions"="vcxproj;vcproj;dsp;mdp;mak;vcp;nativeproj"
"ProjectTemplatesDir"="c:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\.\\VCProjects"
"ItemTemplatesDir"="c:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\.\\VCProjectItems"
"DesignerTemplatesDir"="c:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\.\\DesignerTemplates"
"DevStudioPackageID"=dword:00000004
"ResourcesFolderBehavior"=dword:00000002
"DisableOnlineTemplates"=dword:00000001
@="#10006"

There are no 10.0_Config keys under Wow6432Node.

@CJB867
Copy link

CJB867 commented Jul 6, 2013

I'm getting this problem as well on VS2010 express. Back when the solution files were included, I was able to build it fine after commenting out some VS2010 SP1 checks. Now with the VPC batch files, I get the "ERROR: Unable to find RegKey for .vcproj files in solutions." error.

@Allan537
Copy link

Allan537 commented Jul 6, 2013

Hallo. I had this message but when I tried to Run as administrator. Message changed to:

"C:\Windows\system32>devtools\bin\vpc.exe /hl2mp +everything /mksln eveyrhing.sln
The system cannot find the path specified."

If I will run src\devtools\bin\vpc.exe I'm getting message that quickly closing:

"VPC - Valve Project Creator For Visual Studio, Xbox 360, Playstation 3 <Build: Jun 5 2013 15:27:08>
Copyright 1996-2010, Valve Corporation, All rights reserved.

Source Path: D\mod\modname\scr
Target Platform: win32
Generating for Visual Studio 2010.

Type vpc /h for help..."

@Slashgibber
Copy link

I think I found a fix for this problem. It worked for my so it might work for you.

Go to

HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\VisualStudio\10.0\Projects

Go to one of the keys and create a new string named DefaultProjectExtension and set the value to vcproj.

@joeangry
Copy link

joeangry commented Jul 6, 2013

Allan537, you're getting that message because you're trying to run VPC.exe from a directory where it doesn't exist.

As for everyone else, just wait for Valve to update VPC.exe, there's no point in using all sorts of hacks and workarounds.

@jfmherokiller
Copy link

i did a check with process monitor and it looks for the reg keys here

HKLM\SOFTWARE\Wow6432Node\Microsoft\VisualStudio\10.0\Projects\{1d6d3185-e7ba-44a5-8dbe-00485ef28094}\DefaultProjectExtension

and here

HKLM\SOFTWARE\Wow6432Node\Microsoft\VisualStudio\10.0\Projects\{58839851-977a-4c1b-a0d3-79157d5f2bbf}\DefaultProjectExtension

and here

HKLM\SOFTWARE\Wow6432Node\Microsoft\VisualStudio\10.0\Projects\{F184B08F-C81C-45F6-A57F-5ABD9991F28F}\DefaultProjectExtension

and lastly here

HKLM\SOFTWARE\Wow6432Node\Microsoft\VisualStudio\10.0\Projects\{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}\DefaultProjectExtension

Allan537's fix does work if you apply it to one of the above keys.

I chose the one ending in BC since it was empty.

@jfmherokiller
Copy link

although after fixing the key i get problems stemming from the fact that the projects now end in vcxproj and cant be opened by visual studio 2010 C++ express

@bruced-valve
Copy link
Contributor

What file extension does Visual Studio 2010 C++ Express expect? The .vcxproj file format has been the VC++ standard since VS 2010 and I'm confused as to why the Express edition would change it. This is a new wrinkle.

@Artfunkel
Copy link
Author

It definitely expects vcxproj.

@JoeLudwig
Copy link
Contributor

This is fixed in the update that just shipped.

@ewirch
Copy link

ewirch commented Jun 1, 2014

Looks like it isn't. Using 3b9509d and VS Express 2013:

C:\src-extern\valve-source-sdk-2013\sp\src>createallprojects.bat

C:\src-extern\valve-source-sdk-2013\sp\src>pushd C:\src-extern\valve-source-sdk-2013\sp\src\

C:\src-extern\valve-source-sdk-2013\sp\src>devtools\bin\vpc.exe /hl2 /episodic +everything /mksln everything.sln
VPC - Valve Project Creator For Visual Studio, Xbox 360, PlayStation 3, Xcode and Make (Build: Mar 17 2014 16:55:59)
(C) Copyright 1996-2010, Valve Corporation, All rights reserved.

Source Path: C:\src-extern\valve-source-sdk-2013\sp\src
Target Platform: win32
Generating for Visual Studio 2013.

Parsing: captioncompiler.vpc
Saving... Project: 'Captioncompiler' File: 'captioncompiler.vcxproj'

Parsing: client_hl2.vpc
Saving... Project: 'Client (HL2)' File: 'client_hl2.vcxproj'

Parsing: client_episodic.vpc
Saving... Project: 'Client (Episodic)' File: 'client_episodic.vcxproj'

Parsing: fgdlib.vpc
Saving... Project: 'Fgdlib' File: 'fgdlib.vcxproj'

Parsing: game_shader_dx9_hl2.vpc
WARNING: No shaders found in stdshader_dx9_30.txt
Saving... Project: 'Shaders (HL2)' File: 'game_shader_dx9_hl2.vcxproj'

Parsing: game_shader_dx9_episodic.vpc
WARNING: No shaders found in stdshader_dx9_30.txt
Saving... Project: 'Shaders (Episodic)' File: 'game_shader_dx9_episodic.vcxproj'

Parsing: glview.vpc
Saving... Project: 'Glview' File: 'glview.vcxproj'

Parsing: height2normal.vpc
Saving... Project: 'Height2normal' File: 'height2normal.vcxproj'

Parsing: mathlib.vpc
Saving... Project: 'mathlib' File: 'mathlib.vcxproj'

Parsing: motionmapper.vpc
Saving... Project: 'Motionmapper' File: 'motionmapper.vcxproj'

Parsing: phonemeextractor.vpc
Saving... Project: 'Phonemeextractor' File: 'phonemeextractor.vcxproj'

Parsing: qc_eyes.vpc
Saving... Project: 'QC_Eyes' File: 'qc_eyes.vcxproj'

Parsing: raytrace.vpc
Saving... Project: 'Raytrace' File: 'raytrace.vcxproj'

Parsing: server_hl2.vpc
Saving... Project: 'Server (HL2)' File: 'server_hl2.vcxproj'

Parsing: server_episodic.vpc
Saving... Project: 'Server (Episodic)' File: 'server_episodic.vcxproj'

Parsing: serverplugin_empty.vpc
Saving... Project: 'Serverplugin_empty' File: 'serverplugin_empty.vcxproj'

Parsing: tgadiff.vpc
Saving... Project: 'Tgadiff' File: 'tgadiff.vcxproj'

Parsing: tier1.vpc
Saving... Project: 'tier1' File: 'tier1.vcxproj'

Parsing: vbsp.vpc
Saving... Project: 'Vbsp' File: 'vbsp.vcxproj'

Parsing: vgui_controls.vpc
Saving... Project: 'vgui_controls' File: 'vgui_controls.vcxproj'

Parsing: vice.vpc
Saving... Project: 'Vice' File: 'vice.vcxproj'

Parsing: vrad_dll.vpc
Saving... Project: 'Vrad_dll' File: 'vrad_dll.vcxproj'

Parsing: vrad_launcher.vpc
Saving... Project: 'Vrad_launcher' File: 'vrad_launcher.vcxproj'

Parsing: vtf2tga.vpc
Saving... Project: 'Vtf2tga' File: 'vtf2tga.vcxproj'

Parsing: vtfdiff.vpc
Saving... Project: 'Vtfdiff' File: 'vtfdiff.vcxproj'

Parsing: vvis_dll.vpc
Saving... Project: 'Vvis_dll' File: 'vvis_dll.vcxproj'

Parsing: vvis_launcher.vpc
Saving... Project: 'Vvis_launcher' File: 'vvis_launcher.vcxproj'

Building partial dependency set (libs only)........WARNING: No shaders found in stdshader_dx9_30.txt
.WARNING: No shaders found in stdshader_dx9_30.txt
.....................


Writing solution file C:\src-extern\valve-source-sdk-2013\sp\src\everything.sln.

ERROR: Unable to find RegKey for .vcproj or .vcxproj files in solutions.

C:\src-extern\valve-source-sdk-2013\sp\src>popd

@JoeLudwig
Copy link
Contributor

Please open a new bug for Visual C++ Express 2013. VS2010 is definitely fixed.

In that bug could you look in the registry under HKEY_LOCAL_MACHINE and HKEY_CURRENT_USER and report what you have under Software/Microsoft/VisualStudio? That's what VPC is looking for and not finding.

@DexterHaslem
Copy link

in case it's helpful, I had both VS2010 and VS2013 installed, and VPC worked fine. Once I uninstalled VS2010 it started showing this error again

@bruced-valve
Copy link
Contributor

VPC is supposed to be able to handle VC++ Express. The first thing I need to confirm is that you have VC++ Express 2013 installed, not C# Express or some other language.

Next, can you check the registry to see whether the expected keys are there? We look in HKEY_LOCAL_MACHINE\Wow6432Node\Software\Microsoft%s%d.0\Projects. The %s part can be VisualStudio or VCExpress. The %d part can be 10, 11, or 12 for VS 2010, 2012, or 2013. On 32-bit machines the "Wow6432Node" part of the path is omitted. Within the Projects folder we scan the sub folders looking for one with DefaultProjectExtension set to vcproj or vcxproj. If you search within the Projects directory for DefaultProjectExtension or vcxproj then you should find the key that we are looking for.

If you could look there then that will help us figure out whether the error is on our side or on your machine. I have tested with VCExpress and found the right registry keys, but it is possible that in some configurations the keys get placed elsewhere.

Running SysInternal's procmon while launching VC++ 2013 Express and looking for references to vcxproj or DefaultProjectExtension could also be helpful.

@ewirch
Copy link

ewirch commented Jun 3, 2014

Just for the records: I'm running Windows 8 64bit and VS 2013 Express (C++). The key you're looking for is here:

HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects\{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\DefaultProjectExtension

I haven't found the GUID anywhere else in the registry.

@bruced-valve
Copy link
Contributor

That's odd that the registry key is only in HKEY_CURRENT_USER. The change to WDExpress from VCExpress makes sense, would explain the bug, and would be easy to fix, but if they've completely moved the data then I need to set up a clean machine with VS 2013 Express for test purposes.

@bruced-valve
Copy link
Contributor

The next version should work.

@OliPro007
Copy link

EDIT: Sorry, I didn't see the previous comment stating the same registry key :/ Oh well, I'll leave it there just in case.

I found the DefaultProjectExtension value for vcxproj/c++ in WDEpress/12.0 config
Here is the exported reg key:

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}]
"DefaultProjectExtension"="vcxproj"
"DesignerTemplatesDir"="C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\DesignerTemplates_WDExpress"
"DevStudioPackageID"=dword:00000004
"DisplayProjectFileExtensions"="#10003"
"DisplayProjectType(VsTemplate)"="#1501"
"ItemTemplatesDir"="C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\VCProjectItems_WDExpress"
"Language(VsTemplate)"="VC"
"NewProjectRequiresNewFolder(VsTemplate)"=dword:00000001
"Package"="{F1C25864-3097-11D2-A5C5-00C04F7968B4}"
"PossibleProjectExtensions"="vcxproj;vcproj;dsp;mdp;mak;vcp;nativeproj"
"ProjectTemplatesDir"="C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\VCProjects_WDExpress"
"ResourcesFolderBehavior"=dword:00000002
@="#10006"

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\AddItemTemplates]

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\AddItemTemplates\TemplateDirs]

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\AddItemTemplates\TemplateDirs{F1C25864-3097-11D2-A5C5-00C04F7968B4}]

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\AddItemTemplates\TemplateDirs{F1C25864-3097-11D2-A5C5-00C04F7968B4}/1]
"SortPriority"=dword:0000000c
"TemplatesDir"="C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\VCProjectItems_WDExpress"
@="#10007"

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\FileExtensions]

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\FileExtensions.xaml]
"EditorFactoryNotify"="{32cc8dfa-2d70-49b2-94cd-22d57349b778}"

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\FileExtensions.xaml\RefactorNotify]

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\FileExtensions.xaml\RefactorNotify{c9164055-039b-4669-832d-f257bd5554d4}]
"NotificationType"=dword:00000000

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\FileExtensions.xaml\SymbolicNavigationNotify]

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\FileExtensions.xaml\SymbolicNavigationNotify{c9164055-039b-4669-832d-f257bd5554d4}]

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\Filters]

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\Filters/1]
"CommonFindFilesFilter"=dword:00000001
"CommonOpenFilesFilter"=dword:00000001
"SortPriority"=dword:00000064
@="#10005"

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\Filters/2]
"CommonOpenFilesFilter"=dword:00000001
"FindInFilesFilter"=dword:00000001
"SortPriority"=dword:000000c8
@="#10011"

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\Filters/3]
"CommonOpenFilesFilter"=dword:00000000
"SortPriority"=dword:0000012c
@="#10012"

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\Filters/4]
"CommonOpenFilesFilter"=dword:00000000
"SortPriority"=dword:00000190
@="#10014"

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\Filters/5]
"CommonOpenFilesFilter"=dword:00000000
"SortPriority"=dword:000001f4
@="#10032"

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\Filters/6]
"CommonOpenFilesFilter"=dword:00000000
"SortPriority"=dword:00000258
@="#10033"

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\Filters/7]
"CommonOpenFilesFilter"=dword:00000000
"SortPriority"=dword:000002bc
@="#10034"

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\ImportTemplates]
"ProjectType"="#10024"
"WizardPageObjectAssembly"="Microsoft.VisualStudio.ImportProjectFolderWizard,version=12.0.0.0,publicKeyToken=b03f5f7f11d50a3a,culture=neutral"
"WizardPageObjectClass"="Microsoft.VsWizards.ImportProjectFolderWizard.VC.PageManager"

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\MSBuildHostObjects]

[HKEY_CURRENT_USER\Software\Microsoft\WDExpress\12.0_Config\Projects{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}\MSBuildHostObjects\DesignTimeMarkupCompilationCT;CompileXaml]
@="{83046B3F-8984-444B-A5D2-8029DEE2DB70}"

@ewirch
Copy link

ewirch commented Jun 9, 2014

That's odd that the registry key is only in HKEY_CURRENT_USER.

Sorry for beieng ambigouos. I found the GUID in the registry only as a child of 12.0_Config/Projects, but mutliple times in different parent roots:

HKEY_CURRENT_USER
HKEY_USERS

@ghost
Copy link

ghost commented Sep 27, 2015

This issue persists on Visual Studio 2015, do I really hate to install VS2013 just for this?

@WeAthFoLD
Copy link

I'm using Visual Studio 2015 and gets the same error.

@rlabrecque
Copy link

Yes, Visual Studio 2013 is required.

@ghost
Copy link

ghost commented Oct 30, 2016

VS 2013 is required to be used?

@rlabrecque
Copy link

Yes, Visual Studio 2013 is required.

@JonTerp
Copy link

JonTerp commented Sep 1, 2017

For anyone looking up this error while trying to get this working on Visual Studio 2017:

As stated above, add the following registry keys if they don't already exist:
HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\VisualStudio\10.0\Projects\{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}

Add string key 'DefaultProjectExtension' and set the data to 'vcproj' and your sln file should generate without issue!

@jtrent238
Copy link

Yes @JonTerp 's #issuecomment-326633328 Worked!

@stevefan1999-personal
Copy link

For anyone looking up this error while trying to get this working on Visual Studio 2017:

As stated above, add the following registry keys if they don't already exist:
HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\VisualStudio\10.0\Projects\{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}

Add string key 'DefaultProjectExtension' and set the data to 'vcproj' and your sln file should generate without issue!

Based on your solution, you can try this little bastard if you're desperate:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\VisualStudio\10.0\Projects\{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}]
"DefaultProjectExtension"="vcproj"

Save the snippet as a .reg file and run it.

@jean-knapp
Copy link

This solves the issues for 64-bit systems. What about for 32-bit systems?

@jean-knapp
Copy link

For anyone looking up this error while trying to get this working on Visual Studio 2017:

As stated above, add the following registry keys if they don't already exist: HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\VisualStudio\10.0\Projects\{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}

Add string key 'DefaultProjectExtension' and set the data to 'vcproj' and your sln file should generate without issue!

This is not entirely right because not every Windows user has that registry path. Instead of using HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node, you should use /reg:32

Source: https://serverfault.com/questions/996626/registry-keys-are-getting-imported-under-hkey-local-machine-software-wow6432node

This also means this is not entirely correct:

For anyone looking up this error while trying to get this working on Visual Studio 2017:
As stated above, add the following registry keys if they don't already exist:
HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\VisualStudio\10.0\Projects\{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}
Add string key 'DefaultProjectExtension' and set the data to 'vcproj' and your sln file should generate without issue!

Based on your solution, you can try this little bastard if you're desperate:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\VisualStudio\10.0\Projects\{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}]
"DefaultProjectExtension"="vcproj"

Save the snippet as a .reg file and run it.

since if a user has the path HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\WOW6432Node\ in registry, this .reg file won`t do anything.

In C#, one piece of code I used in XBLAH's Modding Tool that successfully wrote the correct registry was this:

private void SetVcProjKey()
{ 
    const string keyPath = @"SOFTWARE\Microsoft\VisualStudio\10.0\Projects\{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}";
    const string valueName = "DefaultProjectExtension";
    const string valueData = "vcproj";

    try
    {
        RegistryKey registryKey = RegistryKey.OpenBaseKey(RegistryHive.LocalMachine, RegistryView.Registry32).OpenSubKey(keyPath, true);

        if (registryKey == null)
        {
            // If the key doesn't exist, create it
            registryKey = RegistryKey.OpenBaseKey(RegistryHive.LocalMachine, RegistryView.Registry32).CreateSubKey(keyPath, RegistryKeyPermissionCheck.ReadWriteSubTree);
        }

        // Set the registry value
        registryKey.SetValue(valueName, valueData, RegistryValueKind.String);
    }
    catch (Exception ex)
    {
        MessageBox.Show("Error setting registry key: " + ex.Message);
    }
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests