My question is in regard to the order in which my javascript is executing.
I have a rather lengthy function which is pulling data from a server via $Ajax. The first line of this function calls another function which is supposed to show a full page and partially transparent DIV. The idea is that I put this DIV up to gray out the screen, which lets the user know some work is being done for a few seconds while the function is running. At the end of the function the DIV is made invisible again. That is... how it should work.
Instead the DIV is not shown at all. The main function executes, but my "overlay" is never displayed.
I've tried using setInterval with my ShowOverlay function, but this does not seem to work either. Has anyone run into this issue before and what steps have you taken to remedy it?
In my old Windows Forms development there was a function called Form.Invalidate() which would refresh the screen before moving on. I'm looking for a way to do about the same thing.