mvvmcross - Can't bind tableview cell's "Selected" property -
i have view model
public class complectationsubitemwrapper: mvxviewmodel { public complectationsubitemwrapper () { } private complectationsubitem _complectationsubitem; public complectationsubitem complectationsubitem { { return _complectationsubitem; } set { _complectationsubitem = value; raisepropertychanged(() => complectationsubitem); } } private bool _isselected; public bool isselected { get{ return _isselected; } set { _isselected = value; raisepropertychanged(() => isselected); } } }
how can bind isselected property tablecell's selected? tried:
this.delaybind(() => { var set = this.createbindingset<genericpopovercell, complectationsubitemwrapper>(); set.bind(lbltitle).to(vm => vm.complectationsubitem.title); set.bind(this).for(s => s.selected).to(vm => vm.isselected); set.apply (); });
but not working. seems selected property initialized before binding occures. selectionchangedcommand not suitable because need allowsmultipleselection.
Comments
Post a Comment