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

RadBusyIndicator and RadGridView

1 Answer 322 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Johnny Chung
Top achievements
Rank 1
Johnny Chung asked on 05 Apr 2018, 01:26 AM

Hello,

 

I am currently trying to improve the UX of my application which uses RadGridViews.

At a high level, my current workflow is as follows: I my set RadBusyIndicator binding to true, fire a background worker to perform some work on a datatable (which is binded to the RadGridView) then set RadBusyIndicator binding to false on worker completed. 

There are two problems I am encountering:

1) When the datatable has changed, the updating of the RadGridView blocks the UI thread, causing RadBusyIndicator to freeze. If the datatable is large enough, this can effectively freeze the application for quite some time. What would be the best way to show some kind of progress dialog for this?

2) The first time the RadGridView loads, the data_loaded event is fired. However when the datatable has changed and the RadGridView has updated, data_loaded event isnt fired. Is there an event I can monitor for this?

 

 

1 Answer, 1 is accepted

Sort by
0
Sia
Telerik team
answered on 09 Apr 2018, 10:50 AM
Hello,

The BusyIndicator is useful only for background operations that does not affect UI, in other words you cannot use it to wait for UI to render. Being part of the WPF framework, the BusyIndicator is rendered on the main thread. If the UI is rendering and freezes the busy indicator will also freeze. 

A possible approach which you can try is to open a new window on a separate main thread and load the busy indicator there. The general downside of trying to show some busy indication for the rendering in WPF is that the framework doesn't have a mechanism that tells you the rendering has finished. 

Regarding the DataLoaded event, it depends on the action you want to trigger. Generally the Loaded and DataLoaded events are used but you can see all events in our overview. 

Regards,
Sia
Progress Telerik
Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which allow you to write beautiful native mobile apps using a single shared C# codebase.
Tags
GridView
Asked by
Johnny Chung
Top achievements
Rank 1
Answers by
Sia
Telerik team
Share this question
or