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

How do I prevent PullToRefreshIndicator go to invisible.

3 Answers 51 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.
지혜
Top achievements
Rank 1
지혜 asked on 08 Dec 2014, 01:18 PM
I want to show PullToRefreshIndicator even though a listbox has no items.
Could tell me how to do?

3 Answers, 1 is accepted

Sort by
0
Rosy Topchiyska
Telerik team
answered on 10 Dec 2014, 05:14 PM
Hello,

Thank you for contacting us.

You can set the RadDataBoundListBox.ShowPullToRefreshWhenNoData property to true to enable the pull to refresh functionality when the ItemsSource of the control is empty.

I hope this helps. Please, let us know if you have further questions.

Regards,
Rosy Topchiyska
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
지혜
Top achievements
Rank 1
answered on 16 Dec 2014, 10:32 AM
I found a case that PullToRefresh Indicator is not shown even though ShowPullToRefreshWhenNoData property set to True. I'm attaching a sample project. Please fix it if it is a bug.


=======xaml=====================
<telerik:RadDataBoundListBox
                x:Name="listBox"
                CacheMode="BitmapCache"
                IsTabStop="False"
                IsPullToRefreshEnabled="True"
                ShowPullToRefreshWhenNoData="True"
                HorizontalContentAlignment="Stretch"
                DataVirtualizationMode="OnDemandAutomatic"
                Visibility="Collapsed"/>
================xaml.cs================
public MainPage()
        {
            InitializeComponent();
            Loaded += MainPage_Loaded;
        }
        async void MainPage_Loaded(object sender, RoutedEventArgs e)
        {
            await Task.Delay(1000);
            listBox.Visibility = System.Windows.Visibility.Visible;
        }




0
Rosy Topchiyska
Telerik team
answered on 18 Dec 2014, 04:20 PM

Hello,

Thank you for the example. Indeed there is a problem with the PullToRefreshIndicator when the listbox Visibility is initially set to Collapsed. Our developers will further investigate this issue. As a workaround you can create the listbox with Visibility set to Visible and collapse it later, when the control has been loaded.

<telerikPrimitives:RadDataBoundListBox ShowPullToRefreshWhenNoData="True" Loaded="ListBoxLoaded" IsPullToRefreshEnabled="True"/>
private void ListBoxLoaded(object sender, System.Windows.RoutedEventArgs e)
{
    (sender as RadDataBoundListBox).Visibility = System.Windows.Visibility.Collapsed;
}

I hope this helps. I have updated your Telerik points as a token of gratitude for bringing this issue to our attention. Feel free to contact us should you have any other problems.

Regards,

Rosy Topchiyska
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.

 
Tags
DataBoundListBox
Asked by
지혜
Top achievements
Rank 1
Answers by
Rosy Topchiyska
Telerik team
지혜
Top achievements
Rank 1
Share this question
or