View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Don Guillett Don Guillett is offline
external usenet poster
 
Posts: 10,124
Default Adding a new Sheet but not making it the Active Sheet

There is another way I can't remember right now but try this.

Sub addshtwoactive()
goback = ActiveSheet.Name
MsgBox goback
Sheets.Add
Sheets(goback).Select
End Sub

--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"David" wrote in message
ups.com...
Hi

I want to add a new sheet to a workbook but not make it the active
sheet, is that possible?

I've written some code that loops through a worksheet, that is
referred to as the active sheet and then outputs the results onto
another, new sheet in the same workbook. I want to refer to the new
sheet by it's name and keep the active sheet as the active sheet.

Failing that how do you make a sheet active or not?

Thanks.