PDA

View Full Version : How to learn OS to open file with a proper program



Salazaar
29th October 2007, 12:15
Hi. I've got a question.I create a program which elements are .exe file and some other (not exe) needed to launch the program. Than, user can save what he has done to a file with .di suffix. When a user downloads this program, and want to open he's .di file, he's asked which program does he want to use to open it. So the question it, how to do that system already knows that this type of files is opened by my program?
Regards

jacek
29th October 2007, 12:42
You will have to use platform-specific mechanisms for this. On windows it's a matter of adding a key to the registry.

Salazaar
29th October 2007, 12:46
You will have to use platform-specific mechanisms for this. On windows it's a matter of adding a key to the registry.
Yep, but how to do that this is set automatically to a person which installs this program

jacek
29th October 2007, 13:40
It depends how you install the application. For example NSIS can do this without any problems.

Salazaar
29th October 2007, 14:12
It depends how you install the application. For example NSIS can do this without any problems.
Really? NSIS is one or installator I was looknig at in past days, but I didn't know this feature

jacek
29th October 2007, 22:49
http://nsis.sourceforge.net/How_can_I_associate_a_file_extension_with_my_appli cation