On Mar 31, 2005, at 1:14 AM, graham samuel wrote:I'd like to put up a kind of advisory note to the user saying something like
"Please wait while we process your request"
I don't want any reaction from the user, such as clicking on "OK" or "Cancel" - I just want to warn her/him that it may take some time to complete the next task. During this period, I have a nice animation for the person to look at, but I don't really want to add my note to the animated display. I suppose the usual thing is to put the cursor into 'hourglass' or 'pizza' mode (according to platform) and of course I can do this, but I just want to show my message first.
What's the best way to implement this, do you think?
Graham,
Do you want to keep the user from clicking on other areas of your app while this happens? For some tasks I have a "progress" stack that I display as modal (but doesn't block current script execution). This displays a progress bar (or animation) and keeps the user from clicking on anything else until the process has completed.
If this would work in your case you can do the following:
1) Create a stack. For this example I will name it "myProgress". 2) Attach the script I've included below. 3) To give a name to the progress stack: set the uTitle of stack "myProgress" to "I'm doing something. Hold on." 3) To show the stack: set the uShow of stack "myProgress" to true 4) To hide the stack: set the uShow of stack "myProgress" to false
In my script I have additional properties such as uProgress (updates a progress bar) and uFeedback (updates text displayed to the user). This script just has the basics included.
Note that if you make a mistake during development and forget to close the progress dialog you can hold down the command/control key and click on the window to make it disappear (see the mousedown handler).
[code part snipped]
Thanks Trevor, that's what I need! I did already try to use a modal window and the whole thing seized up, so I was forced to learn how to get out of that (it's in the docs). I had not thought out the issue of whether I wanted the user to be cut out while progress was being made - the answer turns out to be so complex that I think I'll just stop the user until the wait is over just to simplify the logic.
I must say I am being given a huge amount of excellent advice by members of the list just now. Great, isn't it?
Graham
---------------------------------------- Graham Samuel / The Living Fossil Co. / UK and France
_______________________________________________ use-revolution mailing list [email protected] http://lists.runrev.com/mailman/listinfo/use-revolution
