Xamarin not updating bindings when page is in background

Viewed 135

I have a viewmodel bound to a page. The viewmodel is updating a property reacting to an event. When the page in is in background (covered by other pages) it doesn't update its UI, even when i execute the viewmodel code on UI thread:

Device.BeginInvokeOnMainThread(() =>
{
        MyProperty = false;
}

Observing this on Android at the moment. Solved but my own answer below.

1 Answers

If i add a single line to this, it works, the page UI gets updated in background:

Device.BeginInvokeOnMainThread(async() =>
{
        await Task.Delay(10);
        MyProperty = false;
}
Related