Maryna Banova
Posts: 1
Joined: 2022-12-28
|
Hello!
I create an app that associate .TDPLan(.xlsx) file with my app. If you right-click on the file it'll suggest opening it with the associate app.
If I add registry keys to the app, it works well. (Default) values are updated.
string appName = "TDPlanStarter";
string appPath = string.Format("\"{0}\"", Application.ExecutablePath);
string executeFileName = System.AppDomain.CurrentDomain.FriendlyName;
Registry.ClassesRoot.CreateSubKey(".TDPlan").SetValue("", appName);
Registry.ClassesRoot.CreateSubKey(appName + @"\DefaultIcon").SetValue("", appPath);
Registry.ClassesRoot.CreateSubKey(appName + @"\shell\open\command").SetValue("", appPath + "\"%1\"");
Registry.ClassesRoot.CreateSubKey(string.Format(@"Applications\{0}\shell\open\command", ppName)).SetValue("", appPath + "\"%1\"");
I added the same registry keys in the setup project.
[img]https://drive.google.com/file/d/1JOcQ9-tHRkklA6YV1AJDqWmRvgBIwdNs/view?usp=share_link[/img]
After installing the app I have two (Default) values: one with blank and another with a value. The file doesn't open by the associate app
[img]https://drive.google.com/file/d/1afVKeLL1Z8l3BdU1t0dsWCrFKE9xyVZn/view?usp=share_link[/img]
How I can update the (Default) value in the registry key by the setup project? |
|
Andrei Smolin
Add-in Express team
Posts: 18829
Joined: 2006-05-11
|
|