Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Date Problems
Message
De
08/04/2003 11:48:24
Gerry Schmitz
GHS Automation Inc.
Calgary, Alberta, Canada
 
 
À
08/04/2003 10:08:20
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Divers
Thread ID:
00775082
Message ID:
00775120
Vues:
16
What you are refering to is typically a "Shop Calendar" and it's created using brute force.

The "calendar" runs 1 to 5 years, and starts on the first "working" day of a starting year. There is a "holiday" table that contains all the holidays.

You generate the calendar by starting from "day one" and counting forward, assigning a number to each day, dropping the "non-work days". DOW() and the holiday table are used to determine non-work days.

At the end, you have a "calendar" that shows only work-days, with each work day also having a sequential "work day number".

The work-days between any two dates is simply the difference of their work day numbers.

Any "due date" can be determined by simple adding the days elapsed to the start date (work date number).

The calendar itself (printed) can easily used by floor personnel also.

>I have a program that allows a user to input orders, orders keyed in up to 1:00pm are considered 'today' orders and any keyed in after 1:00pm are 'tomorrow' orders. Also these orders have a due date that can be up to 15 days not counting weekends and holidays. If an order spans a holiday or a weekend, then those days are skipped and the due date is extended that many more days. Does anyone have any code or snippets than can handle something like this or any ideas that can point me in the right direction.
>
>Thanks
>Ron Olds
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform