How to open a specific view of a uwp application with a secondary tile?

516 Views Asked by At

i currently implement an uwp application and i would like to use a secondary tile. I succeeded to create this tile but i don't find any documentation explaining how to open the view of my application when i click on this tile. Thanks in advance for your help.

1

There are 1 best solutions below

0
On BEST ANSWER

I find a solution to this problem. In fact, i use the same strategy as windows 8. We just need to use the OnLaunched event handler (in App.Xaml.cs) to discover if the app is launched from a SecondaryTile or the primary one

     protected override void OnLaunched(LaunchActivatedEventArgs e)
    {
        bool CalledFromSecondaryTile = false;

        if (!string.IsNullOrEmpty(e.Arguments))
        {
            CalledFromSecondaryTile = true;
        }