App Promotion Trick for Windows Store App

If you are a publisher who has published multiple UWP apps in the windows store and want to add a catalog of all your other apps in your UWP app, then there is no need to write a lot of code to achieve this capability. Microsoft has provided URI scheme to launch the Microsoft Store app to specific pages in the store. We can use search capability to find products from a specific publisher and simply launch that URI using LaunchUriAsync API method.

For ex. in order to launch all products published by some “XYZ Corporation” in the windows store we can simply call the following URI

ms-windows-store://publisher/?name=XYZ Corporation

Following code example demonstrates how this can be achieved using 3 lines of code in Javascript store app

function showPublisherApps() {
    var publisherDisplayName = "Microsoft Corporation"; // Change this to your publisher name
    var uri = new Windows.Foundation.Uri("ms-windows-store://publisher/?name=" + publisherDisplayName);
    var options = new Windows.System.LauncherOptions();
    Windows.System.Launcher.launchUriAsync(uri, options);
}

Simply call this method on on some action such as a button click and it will launch a new popup window containing all apps from the specified publisher.

Link: MS Windows Store – URI Scheme Reference


Leave A Comment

Your email address will not be published.