これがあなたが探しているものかどうかはよくわかりませんが、アプリが読み込まれたらタイルを交換していただけますか? ややこのように:
/// <summary>
/// Creates or replaces a tile with a Title and a parameter
/// </summary>
public void replaceTile()
{
//ShellTile TileToFind = ShellTile.ActiveTiles.First();
string tileTitle = "Title of the Tile";
//You might want to use your Parameter from the toast here as the PageName
ShellTile TileToFind = FindTile( "/PageName.xaml?parameter" );
StandardTileData NewTileData = new StandardTileData
{
Title = tileTitle,
BackgroundImage = new Uri( "/Resources/tile_icon.png", UriKind.Relative ),
Count = 0,
BackTitle = "",
//BackBackgroundImage = new Uri("/Resources/appicon_large.png", UriKind.Relative),
BackBackgroundImage = new Uri( "", UriKind.Relative ),
BackContent = ""
};
// Application should always be found, since it is always the first tile (even if not on homescreen)
if ( TileToFind == null )
{
// Update the Application Tile with the NewTileData
//TileToFind.Update( NewTileData );
//Or replace an existing (second) tile with the new, updated Tile
//ShellTile alreadyExistingTile = FindTile( "/PageName.xaml?parameter" );
//if ( alreadyExistingTile != null )
//{
// alreadyExistingTile.Delete();
//}
ShellTile.Create( new Uri( "/PageName.xaml?parameter=" + newParameter, UriKind.Relative ), NewTileData );
}
else
{
TileToFind.Update( NewTileData );
}}