Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Guys I have a problem
I created these procedures to execute when the file is opened. Th Base Wksht gets created, however if I open it up again and the bas wksht is already there it gives me an error. I need to have the bas wkst recreated every time the file opens. So basically base wkst need to be deleted before the program steps in copyinsameworkbook. Can you guys help me out? Sub auto_open() CopyInSameWorkbook End Sub Sub CopyInSameWorkbook() ' Copying the entire sheet Sheets("x").Select Sheets("x").Copy Befo=Sheets(2) Sheets(2).Name = "Base" End Su -- Message posted from http://www.ExcelForum.com |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Sub auto_open()
application.displayalerts = False On Error Resume Next Sheets("Base").Delete On Error Goto 0 Application.DisplayAlerts = True CopyInSameWorkbook End Sub -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "kaj1104 " wrote in message ... Guys I have a problem I created these procedures to execute when the file is opened. The Base Wksht gets created, however if I open it up again and the base wksht is already there it gives me an error. I need to have the base wkst recreated every time the file opens. So basically base wkst needs to be deleted before the program steps in copyinsameworkbook. Can you guys help me out? Sub auto_open() CopyInSameWorkbook End Sub Sub CopyInSameWorkbook() ' Copying the entire sheet Sheets("x").Select Sheets("x").Copy Befo=Sheets(2) Sheets(2).Name = "Base" End Sub --- Message posted from http://www.ExcelForum.com/ |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
how to take data from 2 or 3 wksts and condese it on 1? | Excel Discussion (Misc queries) | |||
Summing from multiple wksts - incomprehensible #VALUE error | Excel Worksheet Functions | |||
how prevent formula in cell from deleting when deleting value???? | New Users to Excel | |||
a similar convention for tabs/wksts as in for R[1]C[1]? | Excel Discussion (Misc queries) | |||
Deleting Hyphens or Dashes from multiple cells without deleting the remaining content | Excel Programming |