标签:winform style blog color os art
1 开机启动
public static bool SetAutoRun(string keyName, string filePath) { try { RegistryKey Local= Registry.LocalMachine; RegistryKey runKey =Local.CreateSubKey(@"SOFTWARE\Microsoft\Windows\CurrentVersion\Run\"); runKey.SetValue(keyName, filePath); Local.Close(); } catch { return false; } return true; }
SetAutoRun("exeName", Application.StartupPath + "\\step.exe");
C# Winform 注册程序开机启动,布布扣,bubuko.com
标签:winform style blog color os art
原文地址:http://www.cnblogs.com/gordensong/p/3837390.html