How to uniquely identify worksheet
you can refer to the object directly, irrespective of its label
change the name sat from Sheet1 to shMain
in your code
with ShMain
.Range("A1") =.Name
end with
"Vinit" wrote:
Hi friends,
I want to uniquely identify the worksheets in my workbook. I am writing
an add in using VC++. I cant access "CodeName" property of worksheet
using VC++ bcoz it always return blank. The problem in using "Name"
of worksheet is that user can change it any time. There is no event in
excel to keep track of the name change of worksheet. Even I cant use
Worksheets(Index) b'coz sequence can be changed.
Please help me to solve this.
With Best Wishes & Regards,
|