How can I make the Telerik progress bar work?
- by Darien Fawkes
I have a Telerik progress bar in my project:
<telerik:RadProgressManager ID="RadProgressManager" Runat="server" />
<telerik:RadProgressArea ID="RadProgressArea" Runat="server"></telerik:RadProgressArea>
<asp:button id="Button1" runat="server" text="Submit" />
On button click I try to run this method:
private void MethodWhichUpdatesTheProgressContext(UploadedFile file, int countFile)
{
const int total = 100;
RadProgressContext ProgressContex = RadProgressContext.Current;
ProgressContex.SecondaryTotal = "100";
for (int i = 0; i < total; i++)
{
ProgressContex.CurrentOperationText = "Uploading zip file percentage " + i.ToString();
if (!Response.IsClientConnected)
{
break;
}
System.Threading.Thread.Sleep(100);
}
}
Project builds without any errors but progress doesn't change.
How do I properly fire the progress bar animation?
If I put this progress bar on control, it can effect this?