2

I'm trying to provision an application as part of an image prepared in audit mode and then syspreped and then captured. The app is sideloaded since it is a Line Of Business app and the version of Windows Enterprise 2019 LTSC, version 1809 build 17763.107.

I'm basically following these instructions.

I run into some issues immediately however since neither of the options (1, 2, 3 and 4) under Sideloading requirements apply to me since:

  • It wont be joined to a work group
  • Wont be joined to an active directory
  • Is running windows 10 enterprise
  • Is not running Windows embedded 8

Due to this I move on to Configure PCs for Developing Windows apps. The Group Policy Management Editor is not available (Probably since the tablet is not connected to a Group Policy) but I find Local Group Policy Editor. In it I can enable “Allow all trusted apps to install” but I can’t find “Allow development of Windows apps without installing a developer license”. Instead I find “Allows development of Windows Store apps and installing them from an IDE” so I enable that.

I create the app packages in Visual studio 2017 and copy them over to the device in audit mode.

I add the certificate in the package to trusted root certificates.

I run Add-AppxProvisionedPackage -Online -PackagePath C:\Path\To\Package\App.msixbundle -SkipLicense

I get no errors and the only output from the script is:

Path :

Online : True

RestartNeeded : False

If I check using Get-AppxProvisionedPackage I see the app with the correct version.

I sysprep according to instructions here and sysprep processes everything just fine and shuts down.

I restart and boot from a WinPE drive and capture the image using DISM to the same USB-stick also according to instructions here. I skip the split step since I'm capturing to an ntfs drive.

I reboot again and boot from the same USB-stick and deploy the image also according to instructions here.

After deploying I reboot once again and go through OOBE. After OOBE I see the app on the start menu but pressing it does nothing and if I check the properties of it the version is correct but it says that the App is 0 bytes and that the data is 0 bytes. The icon is the correct one however.

I've tried to look through the Microsoft articles on the topic that I have found and for a moment I thought I had the solution in this Server Fault thread but 'Add-AppxProvisionedPackage' does not throw an error so it does not seem to be the same issue.

Any suggestions on how to proceed would be very much appreciated since I'm kinda out of options. Thanks in advance!

2 Answers2

0

Navigate to C:\windows\system32\ and search for the sysprep folder, go to properties change the ownership of the folder to to the local admin by  changing the permissions in Advance menu.2.  After you take the ownership of the folder you can open sysprep\actionfiles and edit the Generalize.xml and remove the following entry from there. 3. Save as  the Generalize.xml on any desired location and then rename the existing Generalize.xml to old and replace it with the new one.4. Run sysprep Generalize and see if that works for you.

0

The issue was that I had not manually specified the dependencies for the platform that the app was to be deployed too.

The app was built for Arm, x86 and x64 in Visual studio code. The folder produced by visual studio code contained the .msixbundle and some other files and folders. One of the folders was called Dependencies and in there were folders named Arm, x86 and x64. I was deploying to x64 and that folder contained 3 files for me:

  • Microsoft.NET.CoreFramework.Debug.2.2.appx
  • Microsoft.NET.CoreRuntime.2.2.appx
  • Microsoft.VCLibs.x64.Debug.14.00.appx

The solution was to specify these as dependencies in the Add-AppxProvisionedPackage call.

So the call that fixed this for me was:

Add-AppxProvisionedPackage -Online -PackagePath C:\Path\To\Package\App.msixbundle –DependencyPackagePath C:\Path\To\Package\Dependencies\x64\Microsoft.NET.CoreFramework.Debug.2.2.appx,C:\Path\To\Package\Dependencies\x64\Microsoft.NET.CoreRuntime.2.2.appx,C:\Path\To\Package\Dependencies\x64\Microsoft.VCLibs.x64.Debug.14.00 -SkipLicense

Windows still says that the app is 0 bytes and it only has 88 kB of data but it is working as intended.

Glad I got it working but kind of bummed that there are no error messages for the missing dependencies.