Home |
Search |
Today's Posts |
#7
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
the code worked fine for me when used on any sheet that was active.
Produced the correct name. -- Regards, Tom Ogilvy "Hammer_757" wrote in message ... I spoke too soon :( Starting with Tom's sugestion, I came up with the following which works fine as long as I am on the first worksheet: Sub SheetNumberUpdate() 'Updates sheet number cell to match sheet (tab) name ActiveSheet.Range("E54").Font.Bold = False 'clears cell formating ActiveSheet.Range("E54").Value = "Sheet " & ActiveSheet.Name 'copies worksheetname to cell "Sheet #####" ActiveSheet.Range("E54").Characters(1, 5).Font.Bold = True 'sets the word "Sheet" to bold font End Sub However, when I use it on one of the other worksheets, say sheet 5 or 6, the cell is updated with the sheet name from the first worksheet. I thought by using Activesheet. Range and Activesheet.name and making sure the desired sheet is active this would work. what am I missing? -- Hammer_757 ------------------------------------------------------------------------ Hammer_757's Profile: http://www.excelforum.com/member.php...fo&userid=7413 View this thread: http://www.excelforum.com/showthread...hreadid=400037 |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Use a range value in place of sheet name | Excel Discussion (Misc queries) | |||
Automatically place text in one cell into cell in another sheet | New Users to Excel | |||
how do I place the sheet tab name in my spreadsheet by formula? | Excel Worksheet Functions | |||
Is there a formula that will place the sheet name in a cell? | Excel Worksheet Functions | |||
How do i place a graphic BEHIND an excel sheet? | Excel Programming |