what is the dialogue that comes up? This is usually cause by a program not shutting down properly and windows gives a message and 30 seconds before it cuts the legs of the program and forces it to shut down. The way to solve this would be to sort the software that is giving the problem or not run it.
Just actually read the thread so what version are you using as there are a few by different people on there. The dialogue will help a lot though if you can post that.