Get the number of working days



I am new to adobe designer and I'm designing a form which takes a start date and an end date from a date time field from which I want to calculate the number of working days excluding saturdays and sundays to be displayed in a text field.......can anybody help me out on this??

formcalc code is:

NumOfDays.rawValue=Date2Num(EndDate.rawValue," D, MMMM,YYYY")-Date2Num(StartDate.rawValue," D, MMMM,YYYY")

which i've placed in the *calculate and then the click events