Hi,
I am stuck on a piece of code that I can't figure out. If I have just inserted and named a new sheet using VBA how can I refer to this new sheet further down in my code? So far I have this...
Sub VlookupDivStocks()
Sheets.Add.Name = InputBox("What would you like to Call this sheet?")
Sheets("2013").Activate
Range("A1").EntireRow.Copy
Sheets(".........").activate <<<<<<what should="" go="" here="" to="" refer="" the="" new="" worksheet="" that="" was="" added="" earlier?
what should go here to refer to the newly inserted sheet?
range("a1").paste
End Sub</what>
I am stuck on a piece of code that I can't figure out. If I have just inserted and named a new sheet using VBA how can I refer to this new sheet further down in my code? So far I have this...
Sub VlookupDivStocks()
Sheets.Add.Name = InputBox("What would you like to Call this sheet?")
Sheets("2013").Activate
Range("A1").EntireRow.Copy
Sheets(".........").activate <<<<<<what should="" go="" here="" to="" refer="" the="" new="" worksheet="" that="" was="" added="" earlier?
what should go here to refer to the newly inserted sheet?
range("a1").paste
End Sub</what>
Last edited: