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

RadProgress during WCF call

1 Answer 40 Views
ProgressArea
This is a migrated thread and some comments may be shown as answers.
Daniel
Top achievements
Rank 1
Daniel asked on 31 Oct 2013, 12:54 AM
I am working on an Import User function, which allows multiple users created for our application at one time (in Active Directory)

When the Import button is triggered using an Ajax call, the grid is processed during the postback, the values are retrieved from the grid, and a collection of user objects is passed to a WCF service.

While that service is processing the collection (anywhere from 1 - 250 users, or potentially more), I would like to be able to notify the user how many users have been imported.

The users are being created in Active Directory which slows down the process.
I'm not sure if the Ajax timed-out, but when I refreshed my grid, half the users showed up, and after a few other refreshes they all showed up.

My problem, is that I do not have a view of what is happening during the import process.  For small batches it would be relatively quick.

But for larger batches, it looks like the Ajax Loading Panel will eventually stop, the grid will be refreshed, even though all the users have not completed being processed (created in Active Directory).

 - How can I accomplish getting either progress synchronously, or asynchronously while the WCF service continues to process the user import request? 

 - And is there an demo, of getting the progress of a WCF service that is processing a collection of objects?

1 Answer, 1 is accepted

Sort by
0
Hristo Valyavicharski
Telerik team
answered on 04 Nov 2013, 03:49 PM
Hi Daniel,

The RadProgressArea has a Progress Data object, which holds the data for the current progress. If you update this object the progress area will be updated too. You may try to configure your WCF service to return the progress after each processed row. Then use jQuery to make calls to get the progress data from the service and update the progress data object.

Regards,
Hristo Valyavicharski
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
Tags
ProgressArea
Asked by
Daniel
Top achievements
Rank 1
Answers by
Hristo Valyavicharski
Telerik team
Share this question
or