1

I want to add my application in the Default Programs list and read articles and questions like these:
How do I add my application in the Default Programs list of Windows Vista/7?
http://msdn.microsoft.com/en-us/library/cc144154%28v=vs.85%29.aspx
and do all of theme but no chance.
I make registry keys like these:

HKEY_LOCAL_MACHINE
   SOFTWARE
      Classes
         TestApp.AssocFile.TA4
            (Default) = TA4 Format
            DefaultIcon
               (Default) = %ProgramFiles%\TestApp\TA4.ico
            shell
               open
                  command
                     (Default) = %ProgramFiles%\TestApp\TA4Opener.exe


HKEY_LOCAL_MACHINE
   SOFTWARE
      Test
         TestApp
            Capabilities
               ApplicationDescription = App Description 
               FileAssociations
                  .ta4 = TestApp.AssocFile.TA4


HKEY_LOCAL_MACHINE
   SOFTWARE
      RegisteredApplications
         TestApp = Software\Test\TestApp\Capabilities   

but when I open Control Panel Set Default programs I can't find my application.
What I missed?

Community
  • 1
  • 1
Ara Deonas
  • 83
  • 1
  • 1
  • 10

1 Answers1

1

Add ApplicationName value under Capabilities, in addition to all values you already have.

HKEY_LOCAL_MACHINE
  SOFTWARE
    Test
      TestApp
        Capabilities
          ApplicationName = Your Application Name

If your application still does not show up in the Set Default Programs list, make sure executable file listed under shell\open\command ( in your example, %ProgramFiles%\TestApp\TA4Opener.exe) has Version resource and Version.CompanyName is not empty.

regmagik
  • 574
  • 3
  • 14
  • I added ApplicationName.Can you give me an example about version? – Ara Deonas Dec 10 '14 at 08:02
  • Double click .rc file in Resource Files folder in Solution explorer. In Resource View, if you don't see Version folder, right click the project node and do Add - Resource, select Version, fill in the fields, at least Company Name. build. test. – regmagik Dec 10 '14 at 08:14
  • Just one problem is application has not any icon and I added DefaultIcon key and set it value to icon address. – Ara Deonas Dec 10 '14 at 08:30
  • Sure but still application has not any icon and I wait until have an complete answer.Do you have an idea? – Ara Deonas Dec 10 '14 at 09:13
  • Does %ProgramFiles%\TestApp\TA4Opener.exe have an icon? if not, add it, similar to adding a version resource. – regmagik Dec 10 '14 at 15:32
  • Sure it have but no icon in Default application list! – Ara Deonas Dec 11 '14 at 20:44
  • try replacing value of DefaultIcon with `%ProgramFiles%\TestApp\TA4Opener.exe,0` – regmagik Dec 11 '14 at 21:49
  • Now it works,thank you.I will update your answer and accept it. – Ara Deonas Dec 12 '14 at 08:09
  • @ara deonas: since you're interested in complete solution, one more thing you can add to your program is the web site URL. it would appear under your program in Default Programs list. http://stackoverflow.com/q/27446817/3220060 – regmagik Dec 17 '14 at 17:57