xaml - RepeaterView<T> in Xamarin Forms Labs -
i'm trying figure out repeaterview in xamarin forms labs.
the background
i have simple entity called entry has property called notes
class entry { public string notes { get; set; } }
in mutual pcl, i've inherited repeaterview create non-generic.
class entryrepeater : xamarin.forms.labs.controls.repeaterview<mykids.core.entities.entry> { }
and xaml of page i'm trying utilize repeater looks this
<rep:entryrepeater itemssource="{binding entries}"> <rep:entryrepeater.itemtemplate> <datatemplate> <viewcell> <viewcell.view> <stacklayout> <label text="{binding notes}" /> </stacklayout> </viewcell.view> </viewcell> </datatemplate> </rep:entryrepeater.itemtemplate> </rep:entryrepeater >
where entries observablecollection.
the issue
the problem binding in datatemplate seems point main model , not 1 item in collection. repeated right number of times.
[0:] binding: 'notes' property not found on 'myapp.viewmodels.entrylistviewmodel', target property: 'xamarin.forms.label.text'
to circle question, error in before versions of xlabs. it's fixed , code above work.
xaml xamarin.forms
No comments:
Post a Comment