Visual Studio “There was a problem sending the command to the program”

Since moving to Visual Studio 2010 on Windows 7 x64, I’ve been getting this error a lot. Every time I open Visual Studio by opening a file rather than running its executable directly, in fact.

Most of the answers seem to revolve around running Visual Studio as a normal user rather than an administrator, but I was already doing that.

Eventually, a reply to this bug provided an answer.

When I checked the key, I saw

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\DDECache\VisualStudio.10.0\system]
"ProcessName"="devenv.exe"
"WindowName"="Visual Studio Application Management Window"
"WindowClassName"="VisualStudioAppManagement"

Deleting the “system” key then opening a file again worked and replaced the key with working values

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\DDECache\VisualStudio.10.0\system]
"ProcessName"="devenv.exe"
"WindowName"="DDEHandler"
"WindowClassName"="DDEHandler"

When it has the correct values (refresh to make sure that it does) remove “set” permissions from your own user so that it can’t replace them with the bad values, to make the change permanent.

Tags:

5 Responses to “Visual Studio “There was a problem sending the command to the program””

  1. drek says:

    Grateful for this post…

    Between your info, and that of the original solution you had found I was finally able to fix my similar problem when trying to open image files in my graphic editor of choice.

    Many google ‘solutions’ never got to the heart of the problem as this does.

    Thanks for sharing!!

  2. Marcus Carey says:

    Change User Account Control settings in the Control Panel. I had this problem running Viusal Studio .NET on Windows 7 64 bit system. After setting the User Account Control settings to never notify, I did not get this message.

  3. George Helyar says:

    Not only is disabling UAC generally a bad idea, only for the computer illiterate, in this case it also didn’t work when I tested it.

  4. Marcus Carey says:

    Yes, disabling UAC is a bad idea; so I started searchig for a better solution. One solution is to create a new task in the Task Scheduler and check “Run with highest privileges.” To run more than one instance of an application, you should also check “Run a new instance in parallel.” After creating “YourTask”, you can create a shortcut with the the folling string SCHTASK.EXE /RUN /TN “YourTask”. This works for running an application, however, it did not work when I double clicked a file associated with the application.

    Then I uncheched both the “Run this program in compatibility mode” and “Run this program as an administor” in the properites dialog. I do not know about other programs, but this works for Visual Studio .NET.

  5. Matt says:

    Didn’t you have to do the exact same thing in a previous version like .NET or something? It seems very familiar and I haven’t used VS since 2003.

Leave a Reply