PC Review


Reply
Thread Tools Rate Thread

How do I calculate the number of weekdays between 2 dates :?

 
 
Chris Hill via .NET 247
Guest
Posts: n/a
 
      17th Nov 2004
Hi

I'm a jnr developer in need of desparate help. Can anyone point me in the right direction for this problem:

I calculate the number of days between 2 user defined dates like this:
Dim DaysInRange As Long

DaysInRange = DateDiff("d", Me.dtp_firstdate.Text, Me.dtp_lastdate.Text) + 1

mod_rptStaffCaseloadAnalysis.p_numDaysInSelectedPeriod = DaysInRange

What I need to do now, is work out the number of weekdays (Mon-Fri) between the dates selected by the user.

I am completely stumped.

Can anyone provide some pointers?

Thanks!

--------------------------------
From: Chris Hill

-----------------------
Posted by a user from .NET 247 (http://www.dotnet247.com/)

<Id>+wr8PUxUVESbdEvStpo9QQ==</Id>
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I calculate the number of weekdays between 2 dates :? Chris Hill via .NET 247 Microsoft VB .NET 3 24th Jan 2005 01:27 PM
How do I calculate the number of weekdays between 2 dates :? Chris Hill via .NET 247 Microsoft VB .NET 1 23rd Dec 2004 09:29 PM
How do I calculate the number of weekdays between 2 dates :? Chris Hill via .NET 247 Microsoft VB .NET 2 31st Oct 2004 01:24 PM
How do I calculate the number of weekdays between 2 dates :? Chris Hill via .NET 247 Microsoft VB .NET 1 17th Oct 2004 11:18 AM
Calculate weekdays from two dates JZ Microsoft Excel Programming 1 16th Oct 2003 09:26 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 05:15 AM.