0

I need to refresh the application when push notification came at background. without opening push notification UI is not affecting .

Have anyone know how to update the application when its minimized where new update came. I have read Background fetch with perform fetch in xamarin forms but didn't get sufficient info anyone help please... Thanks.

Riyas
  • 475
  • 1
  • 8
  • 27

1 Answers1

0

UI actions must be performed on UI thread. If you want to make change on ui in background then you need to do it in MainThread like below:

Device.BeginInvokeOnMainThread (() => {
  labelNotificationCount.Text = "1";
});

For more information, click here

Pavan V Parekh
  • 1,906
  • 2
  • 19
  • 36
  • i didn't get this can you explain little bit where i can use this beginInvokeOnMainThread because when i click on the notification the only one field related to the notification changing on UI other notifications didnt changing without open every one of them. – Riyas Aug 29 '17 at 06:33
  • @Riyas, Please share your ViewModel, Model and Xaml page. – Pavan V Parekh Aug 29 '17 at 09:04