Sfpicker in the listview loses bindings

I have a page in which I'm using sflistview with couple of different item templates, one of those templates has sfpicker in it, at the beginning everything works but after you collapse and extend group in which i have picker, it stops working (simply bindings are gone, so it doesn't have what to display).

 <ContentPage.Resources>
        <ResourceDictionary>

            <!--Listview item template selector reference-->

            <selector:Selector x:Key="TemplateSelector"/>

            <!--Changing Gourp header image selector-->

            <local:BoolToImageConverter x:Key="BoolToImgConverter"/>
            
        </ResourceDictionary>
    </ContentPage.Resources>
    <StackLayout>
        
        <!--Listview initialization-->
        
        <syncfusion:SfListView x:Name="SfListViewGeneral" 
                               ItemSize="60"
                               AllowGroupExpandCollapse="False"
                               ItemTemplate="{StaticResource TemplateSelector}"
                               GroupHeaderSize="70"
                               GroupExpanded="SfListViewGeneral_GroupExpanded"
                               SelectionMode="None">
            <syncfusion:SfListView.LayoutManager>
                <syncfusion:LinearLayout />
            </syncfusion:SfListView.LayoutManager>
            
            <!--Group header template-->
            
            <syncfusion:SfListView.GroupHeaderTemplate>
                <DataTemplate x:Name="GroupHeaderTemplate">
                    <ViewCell>
                        <ViewCell.View>
                            <Frame Padding="5" CornerRadius="5">
                                <Grid>
                                    <Grid.RowDefinitions>
                                        <RowDefinition Height="99*"/>
                                        <RowDefinition Height="1"/>
                                    </Grid.RowDefinitions>
                                    <Grid Grid.Row="0">
                                        <Grid.ColumnDefinitions>
                                            <ColumnDefinition Width="80*"/>
                                            <ColumnDefinition Width="20*"/>
                                        </Grid.ColumnDefinitions>
                                        <customControls:SvgImage x:Name="GroupArrow" 
                                                     Source="{Binding IsExpand, Converter={StaticResource BoolToImgConverter}}" 
                                                     Grid.Column="1"
                                                     HorizontalOptions="End"
                                                     VerticalOptions="Center"
                                                     Clicked="GroupArrow_Clicked"/>
                                        <Label Text="{Binding Key}" 
                                   Grid.Column="0"
                                   Font="Bold, 24"
                                   VerticalOptions="End"/>
                                    </Grid>
                                    <BoxView Grid.Row="1" BackgroundColor="LightGray" />
                                </Grid>
                            </Frame>
                        </ViewCell.View>
                    </ViewCell>
                </DataTemplate>
            </syncfusion:SfListView.GroupHeaderTemplate>         
        </syncfusion:SfListView>
    </StackLayout>

///ViewCell

<Grid>
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="10*"/>
                <ColumnDefinition Width="35*"/>
                <ColumnDefinition Width="55*"/>
            </Grid.ColumnDefinitions>
            <customControls:SvgImage Source="{Binding ItemImage,Mode=TwoWay}" 
                                 Grid.Column="0" 
                                 VerticalOptions="Center" 
                                 HorizontalOptions="Start"/>
            <Label x:Name="lblName"
                Text="{Binding ItemName,Mode=TwoWay}" 
               Grid.Column="1"
               VerticalOptions="End"
               HorizontalOptions="Start"
               Margin="10"
               Font="Bold, 20"/>
            <StackLayout Grid.Column="2">
                <Grid>
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="90*"/>
                        <ColumnDefinition Width="10*"/>
                    </Grid.ColumnDefinitions>
                    <Label x:Name="lblSelectedItem"
                               Grid.Column="0"
                               Text="{Binding ItemPickerSelected}"
                       VerticalTextAlignment="End"
                       HorizontalTextAlignment="End"
                       HorizontalOptions="FillAndExpand"
                       VerticalOptions="Center"/>
                    <customControls:SvgImage Source="Qms.Mobile.Resources.cmdArrowDown24.svg"
                                         HorizontalOptions="End"
                                                 Grid.Column="1"
                                         HeightRequest="24"
                                         WidthRequest="24"/>
                    <Grid.GestureRecognizers>
                        <TapGestureRecognizer Tapped="TapGestureRecognizer_Tapped"
                                                  NumberOfTapsRequired="1"/>
                    </Grid.GestureRecognizers>
                </Grid>

                <BoxView BackgroundColor="LightGray" HeightRequest="1" HorizontalOptions="FillAndExpand"/>
            </StackLayout>
            <picker:SfPicker 
                         x:Name="SfPickerCustom"
                         PickerMode="Dialog"
                         IsEnabled="True"
                         SelectedItem="{Binding ItemPickerSelected}"  
                         ItemsSource="{Binding ItemPickerSource}"
                         OnPickerItemLoaded="SfPickerCustom_OnPickerItemLoaded"
                         ShowFooter="True"
                         SelectionChanged="SfPickerCustom_SelectionChanged"
                         OkButtonClicked="SfPickerCustom_OkButtonClicked"/>
        </Grid>








1 Reply

GP Gnana Priya Namasivayam Syncfusion Team August 13, 2018 04:07 AM UTC

Hi Evaldas, 
  
Thanks for contacting Syncfusion support. 
  
We have checked the reported query “SfPicker in the SfListView losses binding” from our end. We have prepared the sample based on the information given by you. In our sanple we have loaded the listview and inset the SfPicker in the item template of the listview with bindings. We have checked by expanding collapsing the groups. Unfortunately, the reported issue does not replicate at our end. Listview and picker loaded in the view as expected. 
  
For your reference we have attached the sample and you can download it from the below link. 
  
  
Can you please check whether the reported issue occurs in our sample also? If possible, can you please modify the sample to replicate the reported issue in our sample which would highly help us to analyze the query better and provide an appropriate solution.   
  
Regards, 
Gnana Priya N.

Loader.
Up arrow icon