Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Sandy@theblade
 
Posts: n/a
Default Auto Fill workshseet tabs?

I have a workbook with a page for each day of the month, named for the day
and date. I need to copy it for each month. Can I auto fill the tabs on the
worksheets like I would a column?
  #2   Report Post  
Dave Peterson
 
Posts: n/a
Default

Maybe a little macro???

Option Explicit
Sub testme()

Dim iCtr As Long
Dim myDate As Date

myDate = DateSerial(2005, 8, 1)

For iCtr = DateSerial(Year(myDate), Month(myDate), 1) _
To DateSerial(Year(myDate), Month(myDate) + 1, 0)
Worksheets.Add after:=Worksheets(Worksheets.Count)
On Error Resume Next
ActiveSheet.Name = Format(iCtr, "dddd mm_dd_yyyy")
If Err.Number < 0 Then
MsgBox "Error with date: " & Format(iCtr, "mm/dd/yyyy")
Err.Clear
Application.DisplayAlerts = False
ActiveSheet.Delete
Application.DisplayAlerts = True
End If
On Error GoTo 0
Next iCtr

End Sub

If you're new to macros, you may want to read David McRitchie's intro at:
http://www.mvps.org/dmcritchie/excel/getstarted.htm

(ps. I used August of 2005 for the month to add.)

Sandy@theblade wrote:

I have a workbook with a page for each day of the month, named for the day
and date. I need to copy it for each month. Can I auto fill the tabs on the
worksheets like I would a column?


--

Dave Peterson
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Auto Fill Options adarling Excel Discussion (Misc queries) 1 April 8th 05 03:09 AM
How do I auto fill blanks cells immediately below with the same i. leo Excel Discussion (Misc queries) 2 March 16th 05 06:03 PM
Auto fill option box disappeared sbrimley Excel Worksheet Functions 5 February 4th 05 03:21 AM
Auto fill box sue t Excel Discussion (Misc queries) 3 January 13th 05 05:51 PM
Auto Fill Options Patti B Excel Discussion (Misc queries) 3 December 9th 04 12:49 AM


All times are GMT +1. The time now is 05:16 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"