This is a migrated thread and some comments may be shown as answers.

ItemTap event is not invoked.

2 Answers 44 Views
DataBoundListBox
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Hong
Top achievements
Rank 1
Hong asked on 21 Oct 2014, 03:40 PM
Everything works fine, but RadDataBoundListBox_ItemTap is not invoked when an item is tapped.  Instead, RadDataBoundListBox_Tap is invoked.  Could anyone shed some light on this?

<telerikPrimitives:RadExpanderControl.ExpandableContentTemplate>
    <DataTemplate>
        <Grid Margin="0,0,0,24">
            <telerikPrimitives:RadDataBoundListBox ItemsSource="{Binding Items}" IsHitTestVisible="True" ItemTap="RadDataBoundListBox_ItemTap" Tap="RadDataBoundListBox_Tap">
                <telerikPrimitives:RadDataBoundListBox.ItemTemplate>
                    <DataTemplate>
                        <Grid Margin="37,6">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="Auto"/>
                                <ColumnDefinition/>
                            </Grid.ColumnDefinitions>
                            <!--<Image Width="87" Height="87" Source="{Binding ImageThumbnailSource}"/>-->
                            <StackPanel Grid.Column="1">
                                <Button Margin="12,-9,12,0" Grid.Column="1" Content="{Binding Title}" Tag="{Binding Information}" FontFamily="Segoe WP SemiLight" FontSize="{StaticResource PhoneFontSizeLarge}" Foreground="{StaticResource PhoneForegroundBrush}" Click="Button_Click"/>
                                <!--<TextBlock Margin="12,0" Grid.Column="1" Text="{Binding Information}" TextWrapping="Wrap" Foreground="{StaticResource PhoneForegroundBrush}"/>-->
                            </StackPanel>
                        </Grid>
                    </DataTemplate>
                </telerikPrimitives:RadDataBoundListBox.ItemTemplate>
            </telerikPrimitives:RadDataBoundListBox>
        </Grid>
    </DataTemplate>
</telerikPrimitives:RadExpanderControl.ExpandableContentTemplate>

2 Answers, 1 is accepted

Sort by
0
Accepted
Vladislav
Telerik team
answered on 24 Oct 2014, 09:16 AM
Hi Hong,

The RadDataBoundListBox control doesn't fire it's items "Tap events" if some control inside an Item is capturing "Manipulation events". This is done in order to allow using of complex controls inside RadDataBoundLitBoxItem(s). In your case, the Button captures the "ManipulationStarted event" and this prevents the firing of the "RadDataBoundListBox_ItemTap" event.
I hope that this clarifies the described behavior.

Please don't hesitate to ask if you have any additional questions.

Regards,
Vladislav
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Hong
Top achievements
Rank 1
answered on 29 Oct 2014, 09:10 PM
Thank you for the clarification, Vladislav.
Tags
DataBoundListBox
Asked by
Hong
Top achievements
Rank 1
Answers by
Vladislav
Telerik team
Hong
Top achievements
Rank 1
Share this question
or