Imports Microsoft.Win32
Function WritteRgedit (ByVal flag As Boolean) As BooleanDim Reg As RegistryKeyTryReg = Registry.LocalMachine.CreateSubKey ( "software / Microsoft / windows update") Reg.CreateSubKey ( "condition") If flag = True ThenReg.SetValue ( "condition", " 1 ") Elsereg.SetValue (" Condition "," 0 ") End ifreturn Truecatch ExcendReturn Falseend Trynd Function