ActiveSheet CodeName Property Problem

D

Delai

I have a file named "ExcelToolTemplate.xls". In the file's Workbook_SheetActivate function, I have added the ff. codes
Private Sub Workbook_SheetActivate(ByVal Sh As Object
MsgBox ActiveSheet.CodeNam
MsgBox ActiveSheet.Nam
End su

Then I have an application that opens "ExcelToolTemplate.xls". When this is opened and then I add a ne
workbook. e.g. "Book1" Then if you copy one of the worksheets of "Book1" to "ExcelToolTemplate.xls" th
value of ActiveSheet.CodeName is NULL while ActiveSheet.Name has a value.
Am I missing something as to why the value of CodeName is NULL?
Please help. Thanks.
 
D

Delai

May I add also that the worksheet from "Book1" is added to "ExcelToolTemplate.xls" by right-clicking the sheet tab of "Book1" and click "Move or Copy...".
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top