string keyName=@"HKEY_LOCAL_MACHINE\System\CurrentControlSet\services\pcmcia"; string valueName="Start"; if (Registry.GetValue(keyName, valueName, null) == null) { //code if key Not Exist } else { //code if key Exist }