git-tfs-id: [http://192.168.1.10:8080/tfs/AyA]$/SINORT;C126
This commit is contained in:
parent
372ea9884c
commit
08b7adc81f
1 changed files with 16 additions and 16 deletions
|
|
@ -12,22 +12,22 @@ namespace Atesa.Utilitarios
|
||||||
|
|
||||||
private string key = @"SOFTWARE\\Parametros";
|
private string key = @"SOFTWARE\\Parametros";
|
||||||
|
|
||||||
public ObtieneParametros(string subkey = null)
|
// public ObtieneParametros(string subkey = null)
|
||||||
{
|
//{
|
||||||
try
|
// try
|
||||||
{
|
// {
|
||||||
this.key = string.IsNullOrWhiteSpace(subkey) ? this.key : string.Format(@"{0}\{1}", this.key, subkey);
|
// this.key = string.IsNullOrWhiteSpace(subkey) ? this.key : string.Format(@"{0}\{1}", this.key, subkey);
|
||||||
RegistryKey key = RegistryKey.OpenBaseKey(RegistryHive.LocalMachine, Environment.Is64BitOperatingSystem ? RegistryView.Registry64 : RegistryView.Registry32);
|
// RegistryKey key = RegistryKey.OpenBaseKey(RegistryHive.LocalMachine, Environment.Is64BitOperatingSystem ? RegistryView.Registry64 : RegistryView.Registry32);
|
||||||
if (key.OpenSubKey(this.key) == null)
|
// if (key.OpenSubKey(this.key) == null)
|
||||||
{
|
// {
|
||||||
key.CreateSubKey(this.key, RegistryKeyPermissionCheck.ReadWriteSubTree);
|
// key.CreateSubKey(this.key, RegistryKeyPermissionCheck.ReadWriteSubTree);
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
catch
|
// catch
|
||||||
{
|
// {
|
||||||
throw new Exception("The registry key 'ParametrosProceso' does not exist and could not create it");
|
// throw new Exception("The registry key 'ParametrosProceso' does not exist and could not create it");
|
||||||
}
|
// }
|
||||||
}
|
//}
|
||||||
public void AddValueKeyRegedit(string KeyStringName, string KeyStringValue, bool Encrypt)
|
public void AddValueKeyRegedit(string KeyStringName, string KeyStringValue, bool Encrypt)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue