Hey Hurkan,
If you're having problems, try keeping the window open in the background (do not minimize the window) while you're trying to log on.
Another suggestion is to try and wait 30-60 seconds before you try logging into the game, because the window needs to connect to the server.