Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 58056

Listview is not populating the all the items it received from WebAPI.

$
0
0

I have a list view which suppose to populate 200 items but it is only populating 12 items. It is working fine in IOS , its happening only in Andriod.
The code i am using to list the items is
var cell = new DataTemplate (typeof(TextCell));
cell.SetBinding (TextCell.TextProperty, "Name");
cell.SetBinding (TextCell.DetailProperty, new Binding ("Id"));

        listView = new ListView {
            ItemsSource = _employees,
            ItemTemplate = cell
        };
        listView.ItemTapped += HandleItemTapped;


        stackLayout = new StackLayout {
            VerticalOptions = LayoutOptions.StartAndExpand,
            HorizontalOptions = LayoutOptions.StartAndExpand,
            Children = {
                new StackLayout {
                    Children = {
                        listView
                    }
                }
            }

        };
        this.Content = new ScrollView{ 
            Content = stackLayout
        };

Anyhelp would be appreciated.
Thanks.


Viewing all articles
Browse latest Browse all 58056

Trending Articles