2016年3月30日水曜日

ローカルURI の 指定

自分のアプリのAssetsフォルダ内のpngファイルを参照する場合。
ms-appx///local/Assets/***.png

ユーザのフォルダ内のpngファイルを参照する場合。
ms-appdata///local/xxx/***.png




2016年3月27日日曜日

C# code behind で StatusBar の アイコンを隠す

//ステータスバーのアイコンを消す
private async void hideStatusBar()
{
     StatusBar statusBar =
     Windows.UI.ViewManagement.StatusBar.GetForCurrentView();

     // Hide StatusBar
     await statusBar.HideAsync();
}
非同期の処理のため、async await な構造。


AppBarButtonは 個別のボタンとは指定方法が異なる。

AppBarButtonは、SystemUI に属するので、一般の Button などのように色指定などはできない。 AppBarButtonへの色指定等による変更は、CommandBar全体への変更になる。