Paradox Community

Items in pnews.paradox-programming

Subject:Re: code change
Date:Sat, 3 Apr 2021 19:35:14 +0100
From:Michael Kennedy <Info@KennedySoftware.ie>
Newsgroups:pnews.paradox-programming
Sounds like you'd just comment out most of the existing lines, like this:

> proc StartDate(d date) date
> ; proc returns start date for given date
> ; if date is before 16th, start date is begining of month
> ;;	if day(d) < 16 then
> 		return( date(month(d),1,year(d)) )
> ;;	 else
> ;;		return( date(month(d),16,year(d)) )
> ;;	 endIf
> endProc
> 
> proc EndDate(d date) date
> ; proc returns end date for given date
> ; if date is before 16th, end date is 15,
> ; if date if 16th or later, end date is end of month
> ;;	if day(d) < 16 then
> ;;		return( date(month(d),15,year(d)) )
> ;;	 else
> 		return( date(month(d),daysInMonth(d),year(d)) )
> ;;	 endIf
> endProc

Or, make new procs, maybe called StartDateAll(d date) and EndDateAll(d 
date), containing only the above uncommented lines?

...unless I misunderstand?

  - Mike


Copyright © 2004 thedbcommunity.com