View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Susan Susan is offline
external usenet poster
 
Posts: 1,117
Default Putting woirksheet name into a variable

Option Explicit

Sub zeyger()

Dim ws As Worksheet
Dim sName As String

sName = "Zeyger"

Worksheets.Add
ActiveSheet.Name = sName

End Sub


hth!
susan

On Apr 17, 12:38 pm, BZeyger
wrote:
I have a form where a new sheet is created in a workbook. Everytime a sheet
is created it incraments up (sheet1, sheet2, sheet3, sheet4). I was tring to
put the active sheet name into a varable but I do not know the syntax.