enter image description here
When I run these codes and Excel is open, I don\'t get any errors, but when i close exel i get that error. and this is my code: