DataBoundListBox, EmptyContent, EmptyContentTemplate not working ?

2 posts, 0 answers
  1. David
    David avatar
    2 posts
    Member since:
    Sep 2012

    Posted 15 Nov 2013 Link to this post

    Hi,

    I have tried in many ways to get EmptyContent or EmptyContentTemplate working but nothing is working at all. Am I doind something wrong ? I have tried to set EmptyContentTemplate and also EmptyContent but nothing working :-(. UserClubs is an ObservableCollection (Set, and Cleared)

    Here is my code :

    <telerikPrimitives:RadDataBoundListBox
                            ItemsSource="{Binding UserClubs}"
                            EmptyContent="{Binding}"
                            ScrollViewer.HorizontalScrollBarVisibility="Auto"
                            ScrollViewer.VerticalScrollBarVisibility="Disabled"
                            CacheMode="BitmapCache" x:Name="RadClubList">
                             
                            <telerikPrimitives:RadDataBoundListBox.EmptyContentTemplate>
                                <DataTemplate>
                                    <Button Style="{StaticResource ButtonNoStyle}"
                                            Command="{Binding
                                            DataContext.GoToClubsCommand,
                                            ElementName=RadClubList}">
                                        <Image Source="/Assets/Images/Icons/fav-add-fill-icon-green.png"
                                               Stretch="Uniform"
                                               Height="128"
                                               />
                                    </Button>
                                </DataTemplate>
                            </telerikPrimitives:RadDataBoundListBox.EmptyContentTemplate>
                             
                            <telerikPrimitives:RadDataBoundListBox.VirtualizationStrategyDefinition>
                                <telerikPrimitives:StackVirtualizationStrategyDefinition Orientation="Horizontal"/>
                            </telerikPrimitives:RadDataBoundListBox.VirtualizationStrategyDefinition>
                            <telerikPrimitives:RadDataBoundListBox.ItemAddedAnimation>
                                <telerikCore:RadMoveAnimation StartPoint="700,0" EndPoint="0,0" Duration="0:0:1">
                                    <telerikCore:RadMoveAnimation.Easing>
                                        <CubicEase EasingMode="EaseOut"/>
                                    </telerikCore:RadMoveAnimation.Easing>
                                </telerikCore:RadMoveAnimation>
                            </telerikPrimitives:RadDataBoundListBox.ItemAddedAnimation>
                            <telerikPrimitives:RadDataBoundListBox.ItemTemplate>
                                <DataTemplate>
                                    <Button Style="{StaticResource ButtonNoStyle}"
                                            VerticalAlignment="Center"
                                            Command="{Binding
                                            DataContext.NavigateToClubNewsCommand,
                                            ElementName=RadClubList}"
                                            CommandParameter="{Binding}">
                                        <Image Stretch="Uniform" Width="90" Margin="6,0,18,0">
                                            <Image.Source>
                                                <BitmapImage UriSource="{Binding Image}" CreateOptions="BackgroundCreation" />
                                            </Image.Source>
                                        </Image>
                                    </Button>
                                </DataTemplate>
                            </telerikPrimitives:RadDataBoundListBox.ItemTemplate>
                        </telerikPrimitives:RadDataBoundListBox>

    Thanks for your help
  2. Deyan
    Admin
    Deyan avatar
    2039 posts

    Posted 15 Nov 2013 Link to this post

    Hello David,

    Thanks for writing.

    Based on the XAML snippet itself I cannot exactly say why you don't get the expected results. Is it possible for you to open a new support ticket and attach your project so that we can inspect it thoroughly?

    Thanks for your time.

    Regards,
    Deyan
    Telerik
    Have a suggestion or face a problem - you can use the Ideas & Feedback portal to submit ideas, feedback and vote for them.
  3. DevCraft banner
Back to Top