working on progress bar correction and closing