怎样用C#让软件自动启动
现在我想开发一个软件,要让他自动启动,不是把它拖到启动里面
用C#应该怎么写代码
------解决方案--------------------windows服务
------解决方案--------------------写入注册表:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run
------解决方案--------------------哈哈!!
都行
------解决方案--------------------
写注册表咯
RegistryKey  Reg  =  Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Microsoft\Windows\CurrentVersion\Run",true); 
string  sFilePath  =  Application.ExecutablePath; 
Reg.SetValue("程序的名字",sFilePath);