Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 58056

Binding update issue on iOS only....how to resolve?

$
0
0

So in my Master/Detail application I have one detail page that will get information from a webservice and display it. The page itself contains a table view, the table view contains only TextCells. The "Detail" property of each of these TextCells is hardcoded to essentially be the label of the cell; the "Text" property is data bound to a class that will be filled in by the web service. This data class does support INotifyPropertyChanged and calls it as needed. To save data bandwidth, the web service isn't called until the user actually switches to the page for the first time. The web service is called asynchronously.

On Android and WinPhone, the page will show only the "Detail" text of each TextCell until the web service returns, at which point, the "Text" is all filled in appropriately. Which is exactly what I want to happen.

On iOS (both simulator and a physical device), the TextCells don't fill in unless:

1) I tap in them each, which causes them to refresh with the appropriate new data. Mind you, I have to do each TextCell individually, they don't all fill in once I tap one -- only the tapped item updates.

2) If I switch to another detail page in the app, then switch back, the cells will all update as needed.

I have tried using ForceLayout on the page after the web call completes, but it doesn't appear to help this situation. I've tried pre-loading this page and its web data, but it doesn't appear to help either. I only seem to get the page to refresh as described above...any advice on how to get the iOS app to update itself is greatly appreciated.


Viewing all articles
Browse latest Browse all 58056

Trending Articles