• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Day Wise Create Sheets & rename with Day

Abhijeet

Active Member
Hi

I have Template Sheet from that file i want to create day wise sheets & rename with Day
& Sat & Sun highlighted in Red Color

If i select Feb 16 then 29 sheets i want to create
If i select Mar 16 then i want to create 31 sheets with help of that Template file

I want prior to current Date all sheets should be lock with password protect
& Users enable editing not click so macro not run till enable editing so i use force user to enable editing so all sheets should be hide pls look attach file
 

Attachments

  • M&N Orignal.xls
    694 KB · Views: 9
From Combo Box select month & Year then pull one workbook in that 1 sheet call template & 2 sheet is call Master in that all data validation related data & that sheet is hide i want to create day wise sheet from that template sheet & sat & Sun days highlighted in Red color please tell me how to do this with macro
 
I found this code generates data of selected month & year please tell me how to move or copy template worksheet & rename that sheet with day

Code:
Sub GenerateDates()

Dim Days() As Date
Dim DaysInMonth As Long, i As Long
Dim Year As Long, Month As Long

' Example: Feb, 2006 (leap year)
Year = 1996
Month = 2

DaysInMonth = DateSerial(Year, Month + 1, 1) - _
              DateSerial(Year, Month, 1)

ReDim Days(1 To DaysInMonth)
For i = 1 To DaysInMonth
    Days(i) = DateSerial(Year, Month, i)
Next

'Do as you wish with the array of 29 days

End Sub
 
From Combo Box select month & Year then pull one workbook in that 1 sheet call template & 2 sheet is call Master in that all data validation related data & that sheet is hide i want to create day wise sheet from that template sheet & sat & Sun days highlighted in Red color please tell me how to do this with macro
Where are:
ComboBox?
What workbook?

etc...
 
Back
Top