locked
Webview background flashing in Windows 8 app RRS feed

  • Question

  • Hi,

    I am facing a strange issue while loading the Webview for the first time. Whenever the Webview loads, start screen background  flashing (blue screen) happens for a while. It happens only once while loading. Next time everything works properly. Can anybody please tell me how to fix this?


    • Edited by JordanSmith Thursday, January 10, 2013 6:37 AM
    Thursday, January 10, 2013 6:05 AM

Answers

  • Hi Jordan,

    Thanks for the sample.

    I can see the issue you mentioned. Could you try hiding the WebView until system idle?

            protected override void OnNavigatedTo(NavigationEventArgs e)
            {
                this.Dispatcher.RunIdleAsync(new Windows.UI.Core.IdleDispatchedHandler(args => MyWebView.Visibility = Visibility.Visible));
                base.OnNavigatedTo(e);
            }
     <WebView x:Name="MyWebView"  Visibility="Collapsed"  Width="600" Height="600">

    Best regards,


    Min Zhu
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    • Marked as answer by Min ZhuMember Tuesday, January 22, 2013 3:09 AM
    Wednesday, January 16, 2013 8:11 AM
    Moderator

All replies

  • Hello,

    Would you please provide us the whole codes to reproduce this issue,

    You can upload your project to SkyDrive
    http://skydrive.live.com/

    It is not necessary that you send out the whole of your project. We just need a simplest sample to reproduce the problem. You can remove any confidential information or business details from it.

    If you don't want to upload the sample code, you can try to get the paid support from https://getsupport.microsoft.com/

    Best regards,
    Jesse


    Jesse Jiang
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Friday, January 11, 2013 7:18 AM
  • Please check out the sample below. There is a button in the MainPage. Just click on that button, it will navigate to another page having WebView. You will see a Start Screen background flashing while loading WebView.

    http://sdrv.ms/SnQ7Me

    Friday, January 11, 2013 8:01 AM
  • Please check out the sample below. There is a button in the MainPage. Just click on that button, it will navigate to another page having WebView. You will see a Start Screen background flashing while loading WebView.

    http://sdrv.ms/SnQ7Me

    Friday, January 11, 2013 8:02 AM
  • Jesse,

    Did you get a chance to look into the sample? I am still struggling to find out a fix for this issue.

    Wednesday, January 16, 2013 6:47 AM
  • Hi Jordan,

    Thanks for the sample.

    I can see the issue you mentioned. Could you try hiding the WebView until system idle?

            protected override void OnNavigatedTo(NavigationEventArgs e)
            {
                this.Dispatcher.RunIdleAsync(new Windows.UI.Core.IdleDispatchedHandler(args => MyWebView.Visibility = Visibility.Visible));
                base.OnNavigatedTo(e);
            }
     <WebView x:Name="MyWebView"  Visibility="Collapsed"  Width="600" Height="600">

    Best regards,


    Min Zhu
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    • Marked as answer by Min ZhuMember Tuesday, January 22, 2013 3:09 AM
    Wednesday, January 16, 2013 8:11 AM
    Moderator
  • Same issue can be reproduced when we use WebView and AppBar on same page :(

    To reproduce it you can get XAML Webview Control Sample from MSDN: http://code.msdn.microsoft.com/windowsapps/XAML-WebView-control-sample-58ad63f7

    In the last scenario you can see background flashing while hiding appbar (I mean not gray grid background, but system one. To make sure you can change grid background color to white).

    Can anybody help me to fix it?

    Monday, March 25, 2013 2:02 PM