We were working on a Digital Signage application, where we have used the Universal Windows Platform (UWP). The application heavily depends on the data files, i.e., the quality images and videos and their effective navigation is key in this application. The total size of the data files is very huge (more than 25 GB). We can not package this app as there is a restriction on the Package Size that it can be 25 GB maximum per bundle.
In this article, I will be sharing how we shipped this application which had huge data.
- Familiarity with creating Universal Windows Platform (UWP) applications
- Familiarity with Application Design
Load data through the external device
We solved this particular problem by separating application package from its data. By doing this, we reduced the application package size to be as small as possible. Data is shipped separately via an external device, for example, USB. We added the required logic to make the application smart by detecting external drive when inserted and copied the same data into the local machine.
- Keep the Application Package as light as possible and separate this from data files
- Data files need to be shipped separately in the form of USB
- As and when the Application is installed and started for the first time, it checks for the data folder. As it is running for the first time, it will not find data. Depending on the configuration, the installer prompts the user to insert a drive consisting of the data files.
Please find the code logic for detecting external storage and copying data into the AppData folder as mentioned below. At the start of the Application, we’ll verify to check whether data is available locally or not. If not, we try reading it from external storage (App.xaml.cs).
/// Invoked when the application is launched normally by the end user.
/// Other entry points
/// will be used such as when the application is launched to
/// open a specific file.
/// <param name="e">Details about the launch request and process.</param>
protected override async void OnLaunched(LaunchActivatedEventArgs e)
this.DebugSettings.EnableFrameRateCounter = true;
Frame rootFrame = Window.Current.Content as Frame;
// Do not repeat app initialization when the
// Window already has content,
// just ensure that the window is active
if (rootFrame == null)
// Create a Frame to act as the navigation context and navigate
// to the first page
rootFrame = new Frame();
rootFrame.NavigationFailed += OnNavigationFailed;
if(e.PreviousExecutionState == ApplicationExecutionState.Terminated)
//TODO: Load state from previously suspended application
// Place the frame in the current Window
Window.Current.Content = rootFrame;
if (e.PrelaunchActivated == false)
if (rootFrame.Content == null)
// When the navigation stack isn't restored navigate
// to the first page,
// configuring the new page by passing required information
// as a navigation parameter
bool IsDataLoadedFromUSB = false;
if (!await new StorageManager().IsDataAvailable())
await new USBManager().SetUpAppDataFromExternalStorrage();
IsDataLoadedFromUSB = true;
// Ensure the current window is active
This article explained how to package Universal Windows Platform (UWP) Application whose data size is > 25GB. I hope this article guides you in taking an informed decision.
At WalkingTree, we are excited about UWP’s ability to enable developers to build the app which runs on windows-based devices of different sizes. We continue to take advantage of this and love to help you as well.
You can find the complete source code at this repository.
- For information on App Package Requirements – Refer to this link.