Hi,
I am facing some difficulties in getting my progress bar to retrieve its progress from Json results and update the progress bar based on the timer check of every 10 seconds.
I am able to create a json result like this:
{"success":true, "progress":0.2}
I suppose the general idea is that, I need a task with interval set to 10sec, and having the runner to run the task, and when the progress bar starts working, the runner will check on the results from the Json, and update the progress bar as per required.
Code so far:
var task = {
run: function(){
// what to add here?
},
interval: 10000
}
}
Having said so, I am having difficulties on:
- How do I add the Json portion in the task?
- How do I update the progress bar with the given Json result?
Thank you very much.