Post setup - user

masterj

New Member
Hi guys!
Looks like I am stuck for good with this issue. Hopefully someone will be able to help me out.

Soo, I'm trying to run powershell command during the post setup (user) stage. Problem is for some reason it never gets called...

I've even tried adding call cmd and then once the cmd window is loaded I can input the
powershell -command "Add-AppxPackage -Path """$Env:WinDir\appx\48833CODNES.ClassicSolitaireKlondike_1.1.0.0_neutral___jewgw9eww323w.AppxBundle""" -DependencyPath """$Env:WinDir\appx\Microsoft.NET.Native.Framework.1.3_1.3.24211.0_x64__8wekyb3d8bbwe.Appx""", """$Env:WinDir\appx\Microsoft.NET.Native.Runtime.1.4_1.4.24201.0_x64__8wekyb3d8bbwe.Appx""", """$Env:WinDir\appx\Microsoft.VCLibs.140.00_14.0.30035.0_x64__8wekyb3d8bbwe.Appx""""
and everything works. However just adding the powershell -command "Add-AppxPackage -Path """$Env:WinDir\appx\48833CODNES.ClassicSolitaireKlondike_1.1.0.0_neutral___jewgw9eww323w.AppxBundle""" -DependencyPath """$Env:WinDir\appx\Microsoft.NET.Native.Framework.1.3_1.3.24211.0_x64__8wekyb3d8bbwe.Appx""", """$Env:WinDir\appx\Microsoft.NET.Native.Runtime.1.4_1.4.24201.0_x64__8wekyb3d8bbwe.Appx""", """$Env:WinDir\appx\Microsoft.VCLibs.140.00_14.0.30035.0_x64__8wekyb3d8bbwe.Appx"""" to the post setup list doesn't work at all.

Not sure why it doesn't work and I can't find any way to debug as to what is going on...
 

Attachments

  • Screenshot 2021-09-01 224300.png
    Screenshot 2021-09-01 224300.png
    14.8 KB

nuhi

NTLite developer
Staff member
Hi,

if the same command works when ran from CMD, and using OEM product key, try with Unattended - toolbar - OEM SetupComplete.
 

masterj

New Member
Hi,

if the same command works when ran from CMD, and using OEM product key, try with Unattended - toolbar - OEM SetupComplete.
Will it help though? Because other commands are executed, i.e. call cmd is executed (please look at the attached image). I can even input the powershell -command "Add-AppxPackage -Path """$Env:WinDir\appx\48833CODNES.ClassicSolitaireKlondike_1.1.0.0_neutral___jewgw9eww323w.AppxBundle""" -DependencyPath """$Env:WinDir\appx\Microsoft.NET.Native.Framework.1.3_1.3.24211.0_x64__8wekyb3d8bbwe.Appx""", """$Env:WinDir\appx\Microsoft.NET.Native.Runtime.1.4_1.4.24201.0_x64__8wekyb3d8bbwe.Appx""", """$Env:WinDir\appx\Microsoft.VCLibs.140.00_14.0.30035.0_x64__8wekyb3d8bbwe.Appx"""" into loaded cmd directly and it works, but for some reason this command isn't executed automatically (just before the call cmd command)

Maybe there's some command length limit and it gets cutoff or something?
 

Attachments

  • Screenshot 2021-09-02 220302.png
    Screenshot 2021-09-02 220302.png
    13.8 KB

garlin

Moderator
Staff member
DISM doesn't need silly quotes.

DISM.EXE /Online /Add-ProvisionedAppxPackage /PackagePath:%WINDIR%\appx\48833CODNES.ClassicSolitaireKlondike_1.1.0.0_neutral___jewgw9eww323w.AppxBundle /SkipLicense /DependencyPackagePath:%WINDIR%\appx\Microsoft.NET.Native.Framework.1.3_1.3.24211.0_x64__8wekyb3d8bbwe.Appx /DependencyPackagePath:%WINDIR%\appx\Microsoft.NET.Native.Runtime.1.4_1.4.24201.0_x64__8wekyb3d8bbwe.Appx /DependencyPackagePath:%WINDIR%\appx\Microsoft.VCLibs.140.00_14.0.30035.0_x64__8wekyb3d8bbwe.Appx
 

masterj

New Member
Nope, with dism same thing. This command didn't kick off automatically. However if I run it from command line everything works as expected...
 

Attachments

  • Screenshot 2021-09-06 234302.png
    Screenshot 2021-09-06 234302.png
    51.8 KB
  • Screenshot 2021-09-07 000258.png
    Screenshot 2021-09-07 000258.png
    30.5 KB

masterj

New Member
Also please take notice that the problems are occurring only with User - Execution queue. With Machine - Execution queue everything works as expected.

If this will provide any clues I have Windows 10 Enterprise N LTSC version.
 

KikiGames

Member
nuhi so what I am missing here? Maybe I'm using user execution queue incorrectly or something?
Im interested too. Looong time ago I had problems too with some commands and in the end I wasn't sure what applied and what isn't so I used my bat files after installation. But if I share my iso and tell them to run the bat files on the pendrive after installation is not as fluid as just applying automatically.

So yeah. I hope you got an answer bro.
 

crypticus

Well-Known Member
Im interested too. Looong time ago I had problems too with some commands and in the end I wasn't sure what applied and what isn't so I used my bat files after installation. But if I share my iso and tell them to run the bat files on the pendrive after installation is not as fluid as just applying automatically.

So yeah. I hope you got an answer bro.
Add your bat files to setupcomplete..
 
Top