def open_key(self, key, subkey): """ Opens a key """ try: return winreg.OpenKey(key, subkey, 0, winreg.KEY_WRITE) except: return None