Quantcast
Channel: Telerik Forums RSS
Viewing all articles
Browse latest Browse all 78072

GridView Spinner doesn't hide away (IsBusy)

$
0
0
Hello Vitor,

If you want to display the BusyIndicator when grouping and expanding the groups, you can use the following event handlers, which seem to be working fine at my end:

public MainWindow()
{
    InitializeComponent();
    DataContext = new ViewModel();
    var view = (this.DataContext as ViewModel).View;
    view.ItemsLoading += View_ItemsLoading;
    view.ItemsLoaded += View_ItemsLoaded;
    this.RadGridView.Grouping += RadGridView_Grouping;
    this.RadGridView.Grouped += RadGridView_Grouped;
    this.RadGridView.GroupRowIsExpandedChanging += RadGridView_GroupRowIsExpandedChanging;
    this.RadGridView.GroupRowIsExpandedChanged += RadGridView_GroupRowIsExpandedChanged;
}
 
private void RadGridView_GroupRowIsExpandedChanged(object sender, Telerik.Windows.Controls.GridView.GroupRowEventArgs e)
{
    this.busyIndicator.IsBusy = false;
}
 
private void RadGridView_GroupRowIsExpandedChanging(object sender, Telerik.Windows.Controls.GridView.GroupRowCancelEventArgs e)
{
    this.busyIndicator.IsBusy = true;
}
 
private void RadGridView_Grouped(object sender, GridViewGroupedEventArgs e)
{
    this.busyIndicator.IsBusy = false;
}
 
private void RadGridView_Grouping(object sender, GridViewGroupingEventArgs e)
{
    this.busyIndicator.IsBusy = true;
}
 
private void View_ItemsLoaded(object sender, VirtualQueryableCollectionViewItemsLoadedEventArgs e)
{
    this.busyIndicator.IsBusy = false;
}
 
private void View_ItemsLoading(object sender, VirtualQueryableCollectionViewItemsLoadingEventArgs e)
{
    this.busyIndicator.IsBusy = true;
}

I've attached a modified version of my sample project to demonstrate this. Could you verify that you're using the same approach? 

Regards,
Dilyan Traykov
Telerik
Do you need help with upgrading your AJAX, WPF or WinForms project? Check the Telerik API Analyzer and share your thoughts.

Viewing all articles
Browse latest Browse all 78072

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>