I have some workbooks written under Excel 2003 (or earlier).
Some of them contain VBA macros to delete selected worksheets.
The reason that these were coded into VBA macros rather just using the built-in menu option to delete sheets was because where the workbook contained defined names that were local to the sheet, deleting the sheet did not delete the defined ranges - they just hung around as global names filled with #Ref! errors. The VBA macros had the effect of deleting all defined names local to the selected sheet before deleting the sheet.
Now I am beginning to look at Excel 2007, and it looks to me that this procedure may no longer be necessary, otherwise than for backward compatibility (in case someone decides to open it in an earlier version of Excel). Have I got this right, please, that in Excel 2007 the act of deleting a worksheet via the normal non-VBA method also deletes the local names?
Also, I did notice in Excel 2003 there was some instability if you used Excel 1995 macros such as GET.WORKBOOK(1) in a defined name and then tried to copy worksheets etc. Have those instabilities cleared up in Excel 2007, or is it still regarded as unstable to use those features?
Thanks.
Bookmarks