Java and WebServices: showing a Loading window
I'm developing two Swing apps that communicate between each other through Web Services.
As the waiting time for a web service call is a bit long (10 secs sometimes) I was wondering if I could make a JDialog appear during the wait, so a friend told me to do something like this:
Loading winLoad = new Loading("Loading people data...");
<<Web Service call>>
The Loading window shows a gif animated icon and the message "Loading people data..." next to it.
I use this method with different loading messages in every web service call I make but the problem I'm having is that sometimes the window appears but with no icon and no message box; it just remains gray like if it was empty.
Does somebody know what's happening?
Thanks for your help.
P.S: Sorry about my English; I'm from Uruguay and we speak in Spanish. :o