the me.close function does not close immediately. How can i do it ?