comments inline.
Yeah thats exactly what i did lol
store.oncomplete = function(o){
if(o.newVersion){
updateDb(screenId, o.newVersion);
} }
I notice that it keeps firing for a little and then stops, even though all
files have been accessed already, could this be due to the fact that \i am
running it with extJS (js framework) and maybe that is doing something in
the background...
Are you saying that o.newVersion contains a value multiple times right
after one another? That does seem odd if so. Are the values for
newVersion different?
When I log newVersion it comes up blank, ie an empty string, nothing.
The oncomplete event fires x amount of times then stops - normaly if i
wipe out the store and then reload it fires one more time with an empty
result, when i refersh again (without clearing the store) it fires like
around 5 or 6 times at 10 second intervals, again with a blank newVersion.
the thing is that I need to have a timing routine which will make sure it
checks for updates periodically, something like every minute or so, can i
call
checkForUpdate()
every minute, or will this cause problems? what i would do is call it and if
there is a manifest version change I would stop the timing routine and
restart once the download was done... what do you think?
It won't cause problems to call checkForUpdate() periodically. It
seems perfectly reasonable to do that.
Sounds good. Thank you very much for your assistance Aaron.
Adam Docherty