Hide Status bar in Windows Phone 8.1 Universal Apps

前端 未结 3 1518
花落未央
花落未央 2020-12-05 02:08

How to hide the Status bar in Windows Phone 8.1 (C#, XAML)?

In Windows Phone 8 it was done by setting shell:SystemTray.IsVisible=\"Fa

相关标签:
3条回答
  • 2020-12-05 02:27

    With the release of Windows Phone 8.1 SDK comes a new StatusBar. The StatusBar replaces the SystemTray from Windows Phone Silverlight Apps. Unlike the SystemTray, the StausBar can only be accessed via code and some functionality has changed.

    StatusBar statusBar = Windows.UI.ViewManagement.StatusBar.GetForCurrentView();
    
    // Hide the status bar
    await statusBar.HideAsync();
    
    //Show the status bar
    await statusBar.ShowAsync();
    

    Reference: Differences between the new StatusBar in Windows Phone XAML Apps and the SystemTray

    Msdn Reference: StatusBar class

    0 讨论(0)
  • 2020-12-05 02:29

    Here a simple tutorial that explains, working with the Status bar.

    http://denilparmar.blogspot.in/2016/01/working-with-statusbar-in-windows-phone.html

    Hope that helps you :-)

    0 讨论(0)
  • 2020-12-05 02:34
    await Windows.UI.ViewManagement.StatusBar.GetForCurrentView().HideAsync(); 
    await Windows.UI.ViewManagement.StatusBar.GetForCurrentView().ShowAsync(); 
    

    for hiding and showing the system tray

    0 讨论(0)
提交回复
热议问题