Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Make code interactive according to month

Status
Not open for further replies.

netrusher

Technical User
Feb 13, 2005
952
US
Below is the code I have obtained that will copy and save the January Sheet in a workbook. I have 12 sheets
in this workbook, one for every month. Is there a way to automate this code so it will send the sheet based
on what month it currently is? This would be a big help. If the month is March, I would like the code, when ran
to automatically select the correct month (sheet) based on the date.

Code:
Sub SaveSingleSheet()
Sheets("January").Copy
ActiveWorkbook.SaveAs Filename:="s:\eng\Attendance_Vacation\2009\AJJanuary.xls"
ActiveWorkbook.Close
End Sub
 


Please post VBA questions in Forum707.

Skip,
[glasses]Don't let the Diatribe...
talk you to death![tongue]

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top