As the usual behavior of ListView to display the items in a list and it contains a single column. The ItemSource property of Listview accepts the list of data to be displayed and render the same on screen.
The code for a simple list to display the Students of a class would like as in the following pic.

Now let’s customize this ListView in a way to display the Student Name along with the Class and School they belongs to.

As in the image above, the data contains a single record. So to accommodate the data in a single record, Let’s create a Student model class.
|
public class Student { public string StudentName { get; set; } public string Class { get; set; } public string School { get; set; } } |
In order to customize the ListView display, we need to override the ViewCell class.
Like this:
Like Loading...
Categories: Android, Cross Platform Mobile App, iOS, Visual Studio, Windows Phone, Xamarin