Add an App to Startup

Directive Needed:
using Microsoft.Win32;

Code:
RegistryKey rkApp = Registry.CurrentUser.OpenSubKey("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run", true);

Add:
rkApp.SetValue("GamExe", Application.ExecutablePath.ToString());

Delete:
rkApp.DeleteValue("GamExe", false);

Check if Exists:
if (rkApp.GetValue("GamExe") == null)
{
chkRunWithWin.Checked = false;
}
else
{
chkRunWithWin.Checked = true;
}
Wyszukiwarka

Podobne podstrony:
An introduction to difference equation by Elaydi 259
An introduction to the Analytical Writing Section of the GRE
2002 04 Tcp Wrappers Add Protection Layers to Your System
Passkey System v1 2, Add Passkey function to your site
An Introduction to the Kabalah
Geiss An Introduction to Probability Theory
An Introduction To Options Trading Success with James Bittman
An Introduction to Yang Mills Theory
An Introduction to the Study of the Tarot
Eichmann trial An Order to record
21 Wstęp do temperacji 07 10 2009 An introduction to temperament
Surviving Childhood An Introduction to the Impact of Trauma
Add a signal strength display to an FM receiver IC
HOW TO MAKE AN MESSENGE BOX
Turn Young An exploration in to the mind, sex and health
How to make an inexpensive external GPS Antenna

więcej podobnych podstron