string keyName;
string keyValue;
keyName = "MyApp";
keyValue = "My App";
RegistryKey key,subkey;
key = Registry.ClassesRoot.CreateSubKey(keyName);
key.SetValue("",keyValue);
subkey = key.CreateSubKey("shell");
subkey = subkey.CreateSubKey("open");
subkey = subkey.CreateSubKey("command");
subkey.SetValue("",
System.Windows.Forms.Application.StartupPath + "\\MyApp.exe
%1");
subkey = key.CreateSubKey("DefaultIcon");
subkey.SetValue("",System.Windows.Forms.Applicatio n.StartupPath
+ "\\MyApp.exe,0");
keyName = ".bwt";
keyValue = "MyApp";
key = Registry.ClassesRoot.CreateSubKey(keyName);
key.SetValue("", keyValue);
Is this code standard for associating file types? Some of my beta
testers seem to be having problems with it. Am I missing anything?
Thanks for any help.
zerodot
Posted Via Usenet.com Premium Usenet Newsgroup Services
----------------------------------------------------------
** SPEED ** RETENTION ** COMPLETION ** ANONYMITY **
----------------------------------------------------------
http://www.usenet.com