This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
Well, I can't read your code because there is no formatting or indentation. I tried to edit your post, expecting to see indentation and just add the [/CODE] tags around it, but there was no indentation.
But you are just receiving a warning and not an error, you can still run your application. It is just saying that you are going to use COmmunication somewhere where the program will hang and wait until it gets a response, in some cases that is fine.
If you wanted to run the Communication in a seperate thread, therefore not block your app, then you won't see the warning again, but you can disregard the warning too.
You are closing the connection (c.close()) in commandAction(), this is the reason for the warning. Note this is just a warning, but preferably you should do c.close() in another thread (not the system thread that invokes commandAction()).
You will not receive other UI events until commandAction() returns ie in your code until c.close() returns. c.close() is a networking operation and may be a time-consuming operation ...
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com