Application Packaging, How-To Guides, Software Installation Guides

Sideloading Windows Store Apps in Windows 10 with a reusable PowerShell script

So today I was tasked with creating a PowerShell script to sideload Windows Store apps for Windows 10. When I started looking at what I was being asked to do I realized that instead of creating a separate script for each of the apps that they want to load, it would be easier if I could create a generic script that would work for any .appxbundle package file.


First I created a variable for the script path:

$executingScriptDirectory = Split-Path -Path $MyInvocation.MyCommand.Definition -Parent


Then I used the “Get-Childitem” cmdlet with an “-include” parameter to choose the .appxbundle file type:

Get-Childitem $executingScriptDirectory -include *.AppxBundle -recurse 


In order to account for the possibility that there would be more than one .appxbundle package in the folder I am running the script from, I piped the Get-Childitem to a foreach and then called on the “Add-AppxPackage” cmdlet:

Get-Childitem $executingScriptDirectory -include *.AppxBundle -recurse | foreach ($_) {Add-AppxPackage $_.fullname} 


My final code looked like this:

## Set variable for directory where script and appx package reside
$executingScriptDirectory = Split-Path -Path $MyInvocation.MyCommand.Definition -Parent
## Run for every .appxbundle file found in the directory
Get-Childitem $executingScriptDirectory -include *.AppxBundle -recurse | foreach ($_) {
## Install appx package
Add-AppxPackage $_.fullname


Of course, this doesn’t account for regular .appx files, nor does it work when your appx or appxbundle file requires a dependency. Since I didn’t have a need for those options I didn’t expand on my script to include them, but if you do, then at least this script might be a good jumping off point for you.



That’s all for now. Tune in next time for more random software deployment tips!

Amber, Application Packaging, How-To Guides, Software Installation Guides

Lync 2013 Basic Deployment

These instructions are for Microsoft Lync 2013 Basic which has fewer features than Lync 2013 Full. However the basic concept will work for both versions.

Step 1 – Extract files from the Lync Basic installer: %sourcelocation%\lyncentry.exe /extract:%extractionlocation%

Step 2 – From the extracted files run the OCT tool: %extractionlocation%\setup.exe /admin

Step 3 – Use OCT to configure a msp file to your desired customization choices.

Step 4 – To avoid the “First things first” window when user start Lync for the first time add the following reg entries under Additional Content | Add Registry Entries in the OCT tool

lync step5a

lync step5b

Step 5 – Save your settings to your MSP file.

Step 6 – Deploy your MSP. How you deploy is up to you:

  • You can add the MSP file you create to the Updates folder of the extracted files from the source installer and run the install with the command %extractionlocation%\setup.exe. This will install all the msp in the Updates folder including your custom MSP. You will see a Microsoft setup window for a second as it reads the MSP file before installing.
  • You can save the MSP to whatever place you like and use a command that will point to that place; %extractionlocation%\setup.exe /adminfile %yourcustomMSPlocation%
Amber, Application Packaging, Software Installation Guides

Visual C++ 2012 for Enterprise Deployment

Recently I had to package several versions of Visual C++ for a client including the 2012 version. Previous versions of Visual C++ have proven to be pretty straight forward, but 2012 is a little different:

1. Download the installer from Microsoft here.

2. Install the executable on a PC/VM.

3. Navigate to C:\Program Data\Package Cache\.

– There might be several sub folders in this location. Go through them until you find one that has a vcRuntimeMinimum_x86 folder, there will be a separate one with a vcRuntimeAdditional_x86.

– Obviously if you are installing the 64-bit version the folder names with say x64 instead of x86

4. Copy the MSI’s and CAB files in each folder and move them to a folder to stage your package.

5. Create an MST with whatever standards you want and add the public property of ADDEPLOY=1 so that you don’t get this message:

“To install this product, please run Setup.exe. For other installation options, see the Installation section of ReadMe.htm”

6. Install vc_runtimeMinimum_x86.msi first, then install vcRuntimeAdditional_x86.msi second. Include your transforms :

– Example  – “msiexec.exe /i vc_runtimeMinimum.msi TRANSFORMS=MST.mst /qn”

*alternative* – You could also create a chained MSI package for the two so that you don’t have to run two separate installs. Please read here on how to created a non-streamed chained MSI package.