Sheet codename not working
Use the index number instead.
Activeworkbook.Sheets(2).select
OR the sheetname itself
Activeworkbook.Sheets("Sheetname").select
--
Jacob (MVP - Excel)
"Makelei" wrote:
Hi,
XP and Excel2003.
What might be the reason why this is not working (Sheet2 is codename):
Sheet2.Select
I have tried all possibilities that I can imaging, but no. I have another
file and selecting sheet with code name (Sheet4.Select) funtions just fine.
Now using code:
Workbooks.Open Filename:=Doc2
ActiveWorkbook.Sheet2.Select
Opens Doc2 excel file just fine, but does not open the sheet.
Thanks in advance
MakeLei
|