Added Exit Button and functionality