excel vba first working day month

The solution for “excel vba first working day month” can be found here. The following code will assist you in solving the problem.

‘ Returns first working day of month (except public holidays)
Public Function FirstWorkingDayOfMonth(ByVal pDate As Date) As Date
FirstWorkingDayOfMonth = CDate(Application.WorkDay(DateSerial(Year(Date), _
Month(Date), 1), 0))
End Function

Public Sub TestMe()
MsgBox FirstWorkingDayOfMonth(Date)
End Sub

Thank you for using DeclareCode; We hope you were able to resolve the issue.

More questions on [categories-list]

Similar Posts