I am starting the PB and it works well. I am also sending info back in the UpdateProgress method to run some javascript.
At the end of the job i want to hide the PB and show another panel. I cannot seem to stop the task.
Can anyone tell me what i doning wrong??
Code: Visual Basic.NET
e.UpdateProgress(0, "Running")
Do Until fileIsThere = True
fileIsThere = System.IO.File.Exists(Session("strFilePath").ToString())
System.Threading.Thread.Sleep(50)
e.UpdateProgress(i)
If i = 100 Then
i = 0
End If
i = i + 1
Loop
If System.IO.File.Exists(Session("strFilePath").ToString()) Then
Session("FileIsThere") = "True"
End If
e.UpdateProgress(0, "Complete")
If (e.IsStopped) Then 'this is always false
PreviewMultiView.SetActiveView(ApprovalView)
End If
ClientSideOnValueChanged="xcancel_progressBar"
Code: JavaScript
function xcancel_progressBar()
{
var pb = eo_GetObject("ProgressBar1");
if (pb.getExtraData()== "Complete")
{
alert("Task Complete"); works
pb.stopTask();???
document.getElementById("lbViewItem").visible=true;not working
document.getElementById("ApPanel").visible=true;not working
}