When terminating a game, Game.Exit method is called within a Game1.Update method.
A code is as follows.
protected override void Update(GameTime gameTime) { // Game logic is described here. // A game is ended. if (gameExit) { this.Exit(); return; } base.Update(gameTime); }