Käse 1 : 2 Käsereibe
Morgen
irgendwie bekomme ich das nicht so ganz hin...
wenn x86 Betriebssystem:
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\AppCompat]
"DisableEngine"=dword:00000001
"SbEnable"=dword:00000000
"DisablePCA"=dword:00000001
wenn x64 Betriebssystem:
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\AppCompat]
"DisableEngine"=dword:00000001
"SbEnable"=dword:00000000
"DisablePCA"=dword:00000001
[HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Policies\Microsoft\Windows\AppCompat]
"DisableEngine"=dword:00000001
"SbEnable"=dword:00000000
"DisablePCA"=dword:00000001
und zurücktoggln / -setzen:
[-HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\AppCompat]
[-HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Policies\Microsoft\Windows\AppCompat]
und das ganze als .au3 script und nicht als .reg oder .cmd
weiter als so bin ich nicht gekommen... was natürlich auch nicht funktioniert hat -.-
Spoiler anzeigen
#RequireAdmin
Func ToggleHiddenFiles($ApplicationCompatibility=1,$ProgramCompatibility=1,$SwitchBackCompatibility=1)
$RegKey="HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\AppCompat"
$DisableEngine=RegRead($RegKey, "DisableEngine")
$DisablePCA=RegRead($RegKey, "DisablePCA")
$SbEnable=RegRead($RegKey, "SbEnable")
If $ApplicationCompatibility=1 Then
If $DisableEngine=1 Then
RegDelete($RegKey,"DisableEngine")
Else
RegWrite($RegKey, "DisableEngine", "REG_DWORD", 1)
EndIf
EndIf
If $ProgramCompatibility=1 Then
If $DisablePCA=1 Then
RegDelete($RegKey, "DisablePCA")
Else
RegWrite($RegKey, "DisablePCA", "REG_DWORD", 1)
EndIf
EndIf
If $SwitchBackCompatibility=1 Then
If $SbEnable=1 Then
RegDelete($RegKey, "SbEnable")
Else
RegWrite($RegKey, "SbEnable", "REG_DWORD", 0)
EndIf
EndIf
EndFunc
[/autoit]