John & Steven, I don't think adding up the number of days (you could use the HP system vars to calc the number of days :) ) would work...for a business app.... Not that I would know anything about business apps hehehehe I am a Dilbert acolyte after all :) See example below: On 14 Jan, 1997 you would have 14 days in the calendar year. Dividing by 7 would result in 2 with a remainder of 0. The problem is that 14 Jan, 1997 is in the *THIRD* calendar week of the calendar year :( I do remember a series of Library functions in FoxPro 1.1 back in '91 that did these kind of things... wonder if I have these floating around somewhere? Art "I need my Dilbert Fix :)" Bahrs >>> "John D. Alleyn-Day" <[log in to unmask]> 06/14/97 11:24pm >>> Steven Clark wrote: >I need a cobol routine to convert dates into a week of the year. No you don't. All you need is a few lines of code. Add up the days and divide by seven. John D. Alleyn-Day Alleyn-Day International 408-286-6421 408-286-6474 (Fax) [log in to unmask] http://www.Alleyn-Day.com