M B

M B

  • NA
  • 61
  • 12.1k

How to Write System Registry Keys using C#

May 4 2016 6:38 AM
Code :-
 
Microsoft.Win32.RegistryKey mykey;
mykey = Microsoft.Win32.Registry.CurrentUser.CreateSubKey(@"SOFTWARE\Microsoft\Office\15.0\Outlook\Preferences");
mykey.SetValue("MaximumAttachmentSize","51200");
mykey.Close();
 
how can Setvalue something like this :-
 
mykey.SetValue("MaximumAttachmentSize","REG_DWORD","51200");
 
mykey.SetValue(Name,Type,Data)

Answers (1)