View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson[_3_] Dave Peterson[_3_] is offline
external usenet poster
 
Posts: 2,824
Default creating workbooks and worksheets automatically from existing ss

I'm not quite sure how you create the workbooks, but you could modify this:

Option Explicit
Sub testme01()

Dim myPath As String
Dim wkbk As Workbook

myPath = "C:\my documents\excel\test"
If Right(myPath, 1) < "\" Then
myPath = myPath & "\"
End If

Set wkbk = Workbooks.Add
'do some stuff

wkbk.SaveAs Filename:=myPath & Format(Date, "yyyy_mm_dd"), _
FileFormat:=xlNormal

wkbk.close savechanges:=false 'close the workbook????

End Sub


Neil wrote:

I want to create (seperately)a new workbook and a new
worksheet automatically each business day.

I want to name them for the day created.

Can this be done?

Can you help?


--

Dave Peterson