3
1
I have a workbook with some workbook-scoped named formulas. When I copy a worksheet that has some (different) worksheet-scoped names, the copy ends up also having worksheet-scoped names that are identical (other than scope) to the workbook-scoped names.
Example: Say the workbook has workbook-scoped name 'a', the worksheet has worksheet-scoped name 'b'. The copy of the worksheet ends up with 'b' (as expected), and a worksheet-scoped name 'a' that refers to the same formula that the workbook-scoped 'a' does.
I guess I haven't used named formulas enough to have noticed that this is how Excel works, but it's definitely not how I want it to work. Does anyone know how to copy sheets without spewing extra names everywhere? (This includes the related question of how to copy a worksheet from onw workbook to another without also copying over all the workbook-scoped names from the source workbook.)
I'll accept this too unless there is a more direct answer soon. Thanks again! – jtolle – 2010-08-03T14:46:01.507
As with my other question, this answer gets me what I need for convenience in my case. If I were trying to automate this and copy code behind the worksheet, etc., it's not complete. Note that copying cells seems to copy local defined names that are actually used by the copied cells, but not any other local names. (In my case, though what I care about is not creating a local copy of a workbook-scoped name, and this satisfies that need.) – jtolle – 2010-08-07T15:32:55.810