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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Get next working day

Status
Not open for further replies.

vickspills

Programmer
Oct 17, 2018
3
BE
I am new to vbscript. I want to check if date that I pass is a week day or working day date. if the date I am passing is weekend date then get next working date.
In short, I am trying to get next working date.


Can someone help me with this ?
 
Just to be clear - you want to pass a date, and return the next working day; i.e if the date is already a working day, do you still want to return the next working day? This is unclear from the way you have phrased your question)
 
<%if WeekdayName(Weekday("yourdate"))="saturday" then
DateAdd("d",2,"yourdate")
elseif WeekdayName(Weekday("yourdate"))="sunday" then
DateAdd("d",1,"yourdate")
end if%>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top