auto name each new sheet based on cell value


J.W. Aldridge

Need each new sheet's name to be based on cell value.

Should look something like this (but this one doesnt work)

Private Sub Workbook_NewSheet(ByVal Sh As Object)
Dim Ws As Worksheet
Ws.Name = Ws.Range("e2").Text
End Sub

J.W. Aldridge

That's ok. Found one that works. But need to change the code to use

This works....

ActiveSheet.Name = Range("e2").Value

But, since its a date, I need this to work (cant use /'s in sheet

ActiveSheet.Name = Text(E2, "mm.dd.yy").Value

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