To restrict windows mobile key access they are main two methods.
- You can replace the clock.exe in the window folder by empty application.
- You can change some registry values to prevent opening the clock. I will show how we can use C# to do it
using Microsoft.Win32;
// import Microsoft.Win32 top of the class file
Dissable the clock
RegistryKey hklm = Registry.LocalMachine;
hklm = hklm.OpenSubKey(@"\Software\Microsoft\Clock\", true);
System.Byte[] offValue = new byte[1];
offValue[0] = 0x30;
hklm.SetValue("AppState", offValue);
Enable the clock
RegistryKey hklm = Registry.LocalMachine;
hklm = hklm.OpenSubKey(@"\Software\Microsoft\Clock\", true);
System.Byte[] offValue = new byte[1];
offValue[0] = 0x11;
hklm.SetValue("AppState", offValue);
Comments