Welcome Guest Search | Active Topics | Sign In | Register

The Processing Bar RunTask does not run Options
Cubic
Posted: Tuesday, February 22, 2011 4:43:09 PM
Rank: Newbie
Groups: Member

Joined: 2/22/2011
Posts: 2
I copied the demo code to my

protected void RunProcess(object sender, EO.Web.ProgressTaskEventArgs e)
{
e.UpdateProgress(0);

for (int i = 0; i < 100; i++)
{
if (e.IsStopped)
break;

System.Threading.Thread.Sleep(500);

e.UpdateProgress(i);
}

e.UpdateProgress(100);

}


and I hit F5 to debug it. The RunProcess function never gets invoked.

What should I do?

Thanks
Cubic
Posted: Tuesday, February 22, 2011 4:55:55 PM
Rank: Newbie
Groups: Member

Joined: 2/22/2011
Posts: 2
I figure it out by searching old posts.
It seems that I have to use javascript to trigger the processing bar's Runtask.

Here is the js

var pb = eo_GetObject("ProgressBar1");
if (pb && pb.isLoaded())
pb.startTask();
else
window.setTimeout("StartProgressBar()", 100);


It is cool


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.