fixed a syntax error
added the instance ID to the window for later destroying