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!

Entering weekend/holiday VB Script into excel

Status
Not open for further replies.

Quempel

MIS
Jun 23, 2005
15
US
I'm working with an excel spreadsheet which has dates. I want to be able to change the dates to the next business date if the date should fall on a weekend or holiday. I found a couple of scripts but they do not tell me how to submit the script into the VB of an excel spreadsheet. I also need the dates to stay in text format.

Any help would be much appreciated.

Q
 
Hi Q

OK this is a non VB answer in the VBA forum but, there is a worksheet function that will do what you are looking for: WORKDAY

You will need to set up an array of dates for any holidays you want to ignore but it should do what you want.

Fen
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top