c# - Xamarin Forms PCL with Caliburn, only the original thread that created a view hierarchy can touch its views -


in xamarin forms pcl, i'm using caliburn.micro.xamarin.forms implement mvvm data binding. structure of project has viewmodel , view , data binding done this: in viewmodel

private bindablecollection<templistitem> _temperatures;         public bindablecollection<templistitem> temperatures         {             { return _temperatures; }             set             {                 if (value != _temperatures)                 {                     _temperatures = value;                     notifyofpropertychange(() => temperatures);                 }             }         } 

in view

var t2name = new label             {                 fontsize = 17,                 textcolor = (color)application.current.resources["foregroundcolor"]             };             t2name.setbinding(label.textproperty, new binding("temperatures[1].name")); 

i have problem only original thread created view hierarchy can touch views arise when navigate page , suppose related data bindings.

_navigationservice.for<mainviewmodel>().navigate(); 


Comments

Popular posts from this blog

java - Static nested class instance -

c# - Bluetooth LE CanUpdate Characteristic property -

JavaScript - Replace variable from string in all occurrences -