Thread: Copying Sheets
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default Copying Sheets

try running this code

sub ShowNames()
On error goto 0
msgbox "Shoes: " & Activeworkbook.Names("shoes").RefersTo
msgbox "vc: " & activeworkbook.Names("vc").Refersto
msgbox "bags: " & activeworkbook.Names("bags").Refersto
On Error goto 0
End Sub

--
Regards,
Tom Ogilvy

"ben" (remove this if mailing direct) wrote in message
...
I have a workbook with a sub to copy a specific Worksheet and paste a copy

to
the end of the workbook. The workbook contains defined names. The

worksheet
to copy DOES NOT. When I copy this worksheet, I keep getting the error
message that the worksheet you are trying to copy contains a Range or

Formula
with the name (three different names I keep getting ("shoes","vc","bags"),

I
did a search in my defined names list they do not exist, I did i search in

my
formulas and the search text was not found, I even went into my macros and
checked the sheet modules that were being copied, but the text was not

even
found there. Anybody know why this might be happening. NOTE: This only
started happening when i made the sheet modules Option Explicit
ben
--
When you lose your mind, you free your life.