In Windows 7, you have to right click on then 'close Window'. Sometimes when the programme does not close, we have to try to force it to close. So, we must wait for the programme to close. So, next time your computer becomes unresponsive, it shows that some of the programmes are not letting it work normally. Do not immediately use the power switch off operation as it will harm your computer and even some of the data might also be lost. Be patient and let the Windows close the programme.
But you must understand that some of the programmes take quite long even from 10-20 minutes to close. Since, you already know what to do in case of Windows XP I will concentrate on what you should do in Window 7 if you face this problem. Sometimes it is one or two programmes not responding and at times the entire computers get frozen or unresponsive. This type of frozen or non-responsive programmes is usually experienced by users of Windows operating system.