|
public partial class GroupingPage : ContentPage
{
public GroupingPage()
{
InitializeComponent();
}
}
public class GridExt : Grid
{
public GridExt()
{
var gesture = new TapGestureRecognizer();
gesture.Tapped += Gesture_Tapped;
this.GestureRecognizers.Add(gesture);
}
private void Gesture_Tapped(object sender, EventArgs e)
{
//Your code here.
}
} |
|
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:local="clr-namespace:Grouping;assembly=Grouping"
xmlns:listView="clr-namespace:Syncfusion.ListView.XForms;assembly=Syncfusion.SfListView.XForms"
xmlns:dataSource="clr-namespace:Syncfusion.DataSource;assembly=Syncfusion.DataSource.Portable"
x:Class="Grouping.GroupingPage">
<ContentPage.BindingContext>
<local:ContactsViewModel />
</ContentPage.BindingContext>
<ContentPage.Content>
<listView:SfListView x:Name="listView" ItemSize="70" ItemsSource="{Binding contactsinfo}" >
<listView:SfListView.ItemTemplate>
<DataTemplate>
<ViewCell>
<local:GridExt x:Name="grid" RowSpacing="1">
.
.
.
</local:GridExt>
</ViewCell>
</DataTemplate>
</listView:SfListView.ItemTemplate>
</listView:SfListView>
</ContentPage.Content>
</ContentPage> |