Hi all,

I am trying to complete my unattended scripted install of win 8.1 for my developers. I have multiple post installation tasks that install my software and i've worked out all the bugs except for when visual studio 2008 installs, it trys to load some files that get this "Compatibility Error" and all you have to do is click "close" and the install continues, but it hangs up the other apps that need to be installed. Like I said I'm trying to get this fully unattended. I was thinking of maybe changing the registry to not allow the compatibility assistant. Has anyone dealt with this yet? Let me know any suggestions you may have!

2 Comments   [ - ] Hide Comments


  • You could probably just stop the 'Program Compatibility Assistan Service' before the installation begins and if you feel your developers can't live without it - !!!!!! - start it up again on completion.
  • Great! Thank you!
Please log in to comment

Answer this question or Comment on this question for clarity



you can disable thru gpedit or just poke the registry keys

to disable it.



to enable it



Answered 04/11/2014 by: SMal.tmcc
Red Belt

  • SMal.tmcc,
    So I can't get this powershell script to work properly. Here is what I have it doing.

    get-service -DisplayName 'Program Compatibility Assistant Service' | Stop-Service

    Set-service Program Compatibility Assistant Service -startuptype "disabled"

    Set-ItemProperty -Path HKLM:\SOFTWARE\Policies\Microsoft\Windows\AppCompat -Name DisablePCA -Value 1
    Set-ItemProperty -Path HKLM:\SOFTWARE\Policies\Microsoft\Windows\AppCompat -Name DisableEngine -Value 1
    Set-ItemProperty -Path HKLM:\SOFTWARE\Policies\Microsoft\Windows\AppCompat -Name SbEnable -Value 0

    and then my KACE application command is set to.

    powershell.exe -nologo -executionpolicy bypass -noprofile -file Stop_PCA_Reg.ps1

    This tasks follows a few other installs, and by the time everything finishes up, the PCA error still comes up on SQL 2005 and once all the installs are finished, the registry keys have not been set, and the service has not been stopped. But if I just run this on the win8.1 machine it works fine.

    I am still new to both KACE and powershell so also I was wondering if there is a way I can display a CMD prompt to let me know if this is working properly or not.

    Let me know what you think!
    • try running it with cmd.exe as the application and powershell.exe -nologo -executionpolicy bypass -noprofile -file Stop_PCA_Reg.ps1 as the parameters
      • How can I set cmd.exe as the application? Do i still need to upload the script? Would that just be a matter of adding a new bat script and putting the powershell parameters? Sorry, I am pretty new at this.
      • Got thinking may be just because you have no path to the .ps1 file so when you call powershell it assumes the directory you are in. so if your script has c:\windows\system32 the call is looking for the script file in that directory not the kace directory. See my answer for a picture on launching exe and also alternative way to call powershell.
Please log in to comment

You need to upload the Stop_PCA_Reg.ps1 as a dependancy.  then you can call it a couple of ways.


Answered 04/16/2014 by: SMal.tmcc
Red Belt

  • Wow! awesome thanks! Where are you accessing this on the KBOX. I've just been using the post installation task tab and saying add new application. How can I get to the screen this image is showing?
    • I gave you the commands for a kace 1000 script. let me give you commands for a kace2000 post bat script. you do not even need power shell.
Please log in to comment

For the k2000 you need to add these lines in a post batch script

net stop pcasvc

reg.exe add HKLM\SYSTEM\CurrentControlSet\services\PcaSvc /v Start /t reg_dword /d 4 /f

reg.exe add HKLM:\SOFTWARE\Policies\Microsoft\Windows\AppCompat /v DisablePCA /t reg_dword /d 1 /f

reg.exe add HKLM:\SOFTWARE\Policies\Microsoft\Windows\AppCompat /v DisableEngine /t reg_dword /d 1 /f

reg.exe add HKLM:\SOFTWARE\Policies\Microsoft\Windows\AppCompat /v SbEnable /t reg_dword /d 0 /f

HKLM:\SOFTWARE\Policies\Microsoft\Windows\AppCompat -Name DisablePCA -Value 1 - See more at: http://www.itninja.com/question/win-8-1-bypass-compatibility-errors-for-unattended-install-1#answer-90750


Answered 04/16/2014 by: SMal.tmcc
Red Belt

  • Ok. So the script works great if I run it manually on a windows 8 machine, but when it runs as a post install task it is not creating the entries in the registry, and not stopping the service. It almost seems like during the post installation tasks that windows hasn't fully booted up yet. So I am still getting the PCA error window when SQL 2005 tries to install. Any ideas?
    • since it is 64 bit you may have to use HKLM64 instead of HLKM

      Is your kbox 3.6?
      here is one question on how they got PS to work with kace 3.6.
      • Ok... I'll try the 64 change. We are on 3.5.80613
Please log in to comment