Creating a task from code behind
Hello
I am trying to creat taksks associated to panels create from code behind. All works well except I am not able to create the task.
Here definition of task in aspx page :
Code:
<ext:TaskManager ID="TaskManager" runat="server" Enabled="False">
<Tasks>
<ext:Task
TaskID="tskUpdateArrowProgress"
AutoRun="false"
Interval="100">
<DirectEvents>
<Update OnEvent="UpdateArrowProgress"></Update>
</DirectEvents>
</ext:Task>
</Tasks>
</ext:TaskManager>
and what I want to achive from code behind :
Code:
MyTask.Interval = 500
MyTask.TaskID = "tsk" + ds.Tables("UShape").Rows(i).Item("UShapeID").ToString
MyTask.DirectEvents.Update.Call("UpdateArrowProgress")
MyTask.AutoRun = True
TaskManager.AddTask(MyTask)
but
Code:
MyTask.DirectEvents.Update.Call("UpdateArrowProgress")
is not working and I don't now how to associate the directevent function to the task