Search code examples
powershelldism

Installing a language pack using powershell invoking dism.exe command online


**$exefile = "C:\Windows\System32\dism.exe"
$command="C:\Windows\System32\dism.exe /online /add-package /package-path:"+"C:\lang\fr-ca\lp.cab"

Invoke-Expression $command**

I am getting below error and language pack is not getting installed by using above command

Image Version: 10.0.10116.0

Error: 87

The package-path option is not recognized in this context. For more information, refer to the help.


Solution

  • When in doubt, read the documentation. The parameter name is /PackagePath (without hyphen), not /Package-Path.