Are your date fields really date fields and not text or number fields?
Did you set this ups as a calculation field or a number field with an auto-enter calculation?
And are weekdays all that you need to account for? Or do you also need to adjust this value to account for any holidays between your start and end dates?
The calculation--which could be defined as a custom function works for me.
But if you are going to include Holidays, I wouldn't use this method at all. I find it easier to set up a calendar table with one record for each day and then mark the days as either "open" or closed. An auto-enter calculation can mark weekend dates closed automatically and you can seven set up an actual calendar format with portals such that you can just click a button or enter a date into a global date field and run a script, to find and mark a given date as a holiday.
Then a relationship that matches to only dates with an "open" status in the date range specified can be used to count the number of days--which now counts all working days that are not also holidays.