There are a few ASP.NET MVC modal dialog questions on S/O but they are either "page-loading, please-wait" or confirmation modal dialogs (you click on a submit button, and before processing proceeds, you click on an OK or Cancel button in the dialog). My requirement is for a please-wait modal dialog to be displayed after clicking on a submit button, which grays out the web page (i.e., a modal dialog), displaying only a spinning wheel gif and waiting until some long-running (not a huge amount of time, just 10-15 seconds max) server-side code completes. (Right now in our application users sometimes get impatient and start spuriously clicking on the submit button again regardless of the fact that the browser window wait spinner thingamajig is still spinning.) When the server-side code completes, the please-wait dialog should go away.
Note that I found one reference that I think I might be able to use some of the code from:
As you can see, that article is for the "page-loading, please-wait" use case. But the first part of the code, that displays the please-wait dialog I think I could use. IOW, user clicks on the submit button and I use the code in the article on the client-side to display the modal please-wait dialog. The request goes ahead to the server and the controller action method executes. When the server-side code completes, I simply display the view I want (same view in which a div underneath the submit button says "your request has completed" or a different, request complete view - either one) which effectively makes the please-wait dialog go away. Does that make sense to y'all?