fixed bugs with excel opening and closing app