How to associate a file extension to the current executable in C#

后端 未结 9 2291
故里飘歌
故里飘歌 2020-11-22 12:01

I\'d like to to associate a file extension to the current executable in C#. This way when the user clicks on the file afterwards in explorer, it\'ll run my executable with t

9条回答
  •  甜味超标
    2020-11-22 13:01

    Also, if you decide to go the registry way, keep in mind that current user associations are under HKEY_CURRENT_USER\Software\Classes. It might be better to add your application there instead of local machine classes.

    If your program will be run by limited users, you won't be able to modify CLASSES_ROOT anyway.

提交回复
热议问题