Hello and hope everyone doing well. Is it possible to sum all rows height?
My Listview has not equal rows. I have set AutoFitMode="Height"
|
public class ExtendedListView : SfListView
{
VisualContainer container;
public ExtendedListView()
{
container = this.GetVisualContainer();
container.PropertyChanged += Container_PropertyChanged;
}
private void Container_PropertyChanged(object sender, System.ComponentModel.PropertyChangedEventArgs e)
{
double totalHeight = 0;
Device.BeginInvokeOnMainThread(async () =>
{
var extent = (double)container.GetType().GetRuntimeProperties().FirstOrDefault(container => container.Name == "TotalExtent").GetValue(container);
if (e.PropertyName == "Height")
totalHeight = extent;
});
}
} |
Thank you very much!! It works like a charm!! I need to make more research about VisualContainer methods.
Is there any doucumentation about visual container?