老师,开启或取消开机启动项目的代码放在哪个事件里面?谢谢!
Dim starupPath = ProjectPath & "xxx.exe"Dim loca = Microsoft.Win32.Registry.LocalMachineDim run = loca.CreateSubKey("SOFTWARE\Microsoft\Windows\CurrentVersion\Run")'run.SetValue("我的项目", False) '取消开机运行run.SetValue("我的项目", starupPath) '设置开机运行loca.Close()