Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Why Sheet1 is displayed in modules as sheet1
all other sheets are Sheets?
-- Jim at Eagle |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Why Sheet1 is displayed in modules as sheet1
you can change this in the properties window
The (name) property, with the word 'name' in parentheses is the sheet object name....eg change sheet1 to shMain. You can use this in VBA code shMain.Range("A1") = "Main Sheet" The Name property - ie without the parentheses, is the name that appears on the sheet tab, and is the reference used in the Worksheets() collection So for shMain set the Name property to 'Main' Now these two code blocks are equivalent: With shMain .Range("A1") = "Using the object" End With With Worksheets("Main") .Range("A2")="Using the indirect" End With HTH "Jim at Eagle" wrote: all other sheets are Sheets? -- Jim at Eagle |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Why Sheet1 is displayed in modules as sheet1
Yes, the display name is "Entry" but I program using Sheet1. In Project
Explorer it displays as Sheet1(Entry). When I code as Sheet1 and leave the line it changes to sheet1. All other worksheets stay as Sheet2...... Question why am I losing proper case on sheet1 only? "Patrick Molloy" wrote: you can change this in the properties window The (name) property, with the word 'name' in parentheses is the sheet object name....eg change sheet1 to shMain. You can use this in VBA code shMain.Range("A1") = "Main Sheet" The Name property - ie without the parentheses, is the name that appears on the sheet tab, and is the reference used in the Worksheets() collection So for shMain set the Name property to 'Main' Now these two code blocks are equivalent: With shMain .Range("A1") = "Using the object" End With With Worksheets("Main") .Range("A2")="Using the indirect" End With HTH "Jim at Eagle" wrote: all other sheets are Sheets? -- Jim at Eagle |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
sheet1 | Excel Discussion (Misc queries) | |||
=[Book.xls]Sheet1!A1 and not c:\blah\=[Book.xls]Sheet1!A1 | Excel Discussion (Misc queries) | |||
[=Sheet1!A1] - if i use Column A1 ('Sheet1') / A2 ('Sheet2') | Excel Worksheet Functions | |||
How to know whether sheet1 contains any data in it? | Excel Programming | |||
Sheet1 object not Worksheets("Sheet1") | Excel Programming |