We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

sDataGrid Swiping fires SelectedItem

Thread ID:

Created:

Updated:

Platform:

Replies:

127252 Nov 5,2016 07:50 PM Jul 17,2017 05:26 AM Xamarin.Forms 3
loading
Tags: SfDataGrid
Emil
Asked On November 5, 2016 07:50 PM

I followed the documentation and sample for swiping on sfdatagrid. I have swiping and selection together and actually when I do swiping, it fires also selecteditem and I normally have a navigation on another page for details of the row when row is selected. how can I control this? how can I prevent selectedItem is fired when swiping left or right?

        <sfgrid:SfDataGrid ScrollingMode="PixelLine" x:Name="dataGrid" 
                           AutoGenerateColumns="False" AllowSorting="True" AllowDraggingColumn="True" AllowDraggingRow="True"
                           ColumnSizer="Star"   MaxSwipeOffset="150"
                            RowHeight="153"   AllowSwiping="True"
                            SwipeEnded="dataGrid_SwipeEnded"
                            SwipeStarted="OnSwipeStart"                
                            Swiping="OnSwiping"
                           GridTapped="dataGrid_GridTapped"
                           SelectionMode="Single"   ItemsSource="{Binding  AllPrograms}"
                           SelectedItem="{Binding SelectedItem}"> 
          <sfgrid:SfDataGrid.LeftSwipeTemplate>
            <DataTemplate>
              <Grid BackgroundColor="#009EDA">
                <Grid.ColumnDefinitions>
                  <ColumnDefinition />
                  <ColumnDefinition />
                </Grid.ColumnDefinitions>
                <Image Grid.Column="0"
                       BackgroundColor="Transparent"                      
                       HorizontalOptions="Fill"
                       Source="edit.png">
                  <Image.GestureRecognizers>
                    <TapGestureRecognizer>
                      Command="{Binding OnDELETEClick}"
                      CommandParameter="{Binding .}"
                    </TapGestureRecognizer>
                  </Image.GestureRecognizers>
                </Image>
                <Label Grid.Column="1"
                       BackgroundColor="Transparent"
                       LineBreakMode="NoWrap"
                       Text="DELETE"
                       TextColor="White"
                       HorizontalTextAlignment="Start"
                       VerticalTextAlignment="Center" />
              </Grid>
            </DataTemplate>
          </sfgrid:SfDataGrid.LeftSwipeTemplate>

Divakar Subramaniam [Syncfusion]
Replied On November 7, 2016 06:04 AM

Hi Emil, 
 
 
We have confirmed this as a defect and we are currently working in it. 
 
A support incident to track the status of this defect has been created under your account. Please log on to our support website to check for further updates    
 
Regards, 
Divakar. 


Emil
Replied On July 15, 2017 07:56 PM

Hi,

this problem is fixed for sfDatagrid but happening for sfListView also. I am not sure if I should have another ticket for that. can you please check it? thanks,

Emil


Ashok N [Syncfusion]
Replied On July 17, 2017 05:26 AM

Hi Emil,  
  
Sorry for the inconvenience caused.  
  
We have checked the reported issue “Selection events get triggered when swiping is performed in SfListView” at our end by enabling both AllowSwiping as “Single” and SelectionMode as Multiple with the latest SfListView version(v 15.2.0.46). In the sample, we have loaded the SfListView in theMasterDetailPage and enabled the swiping and selection and performed swipe gesture action in both left and right swipe direction and no selection events get triggered as reported and it works as expected at our end. For your reference, we have attached the ensured sample at our end and you can download it from the below link.  
  
  
Could you please check with the above sample? If the issue still persists at your end, we request you to modify the above sample to reproduce the issue with the replication procedure and also, could you please share the below details which would help us to analyze the issue better and update you an appropriate solution.  
  
Could you please share the Xamarin Forms version?. We have ensured in Xamarin Forms v 2.3.4.231. 
Could you please share the SfListView version?. We have ensured in latest version (v 15.2.0.46). 
Could you please share which layout is defined in LayoutManager such as Linear or Grid Layout? 
  
Please let us know if you require further assistance.  
  
Regards,  
Ashok 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;