PDA

View Full Version : Application.Workbooks("try.xls").Close problem



justinferns
10-03-2011, 07:54 AM
Hi,

I'm trying to close an open excel using the code :

Application.Workbooks("try.xls").Close

This above line works in Excel 2007 but not in Excel 2003. It gives me this error: "Subscript out of range"

Can anyone give me a suitable code that would work in Excel 2003?

Thanks
Justin

justinferns
10-03-2011, 09:21 AM
Got the answer!!

Justin