PXRMXDUT ; SLC/PJH - Date utilities for reminder reports. ;05/05/2006 ;;2.0;CLINICAL REMINDERS;**4**;Feb 04, 2005;Build 21 ; BDHELP(HTEXT,TYPE) ;Write the beginning date help. I $D(HTEXT) D HELP(.HTEXT) I '$D(HTEXT) D . N BDHTEXT . S BDHTEXT(1)="This is the beginning date for "_TYPE_" to be included in the creation of" . S BDHTEXT(2)="this report." . D HELP^PXRMXDUT(.BDHTEXT) Q ; EDHELP(HTEXT,TYPE) ;Write the ending date help. I $D(HTEXT) D HELP(.HTEXT) I '$D(HTEXT) D . N EDHTEXT . S EDHTEXT(1)="This is the ending date for "_TYPE_" to be included in the creation" . S EDHTEXT(2)="of this report." . D HELP^PXRMXDUT(.EDHTEXT) Q ; SDHELP(HTEXT) ;Write the single date help. I $D(HTEXT) D HELP(.HTEXT) I '$D(HTEXT) D . N SDHTEXT . S SDHTEXT(1)="This is the date of reminder evaluation for the report" . D HELP^PXRMXDUT(.SDHTEXT) Q ; FDR(BDATE,EDATE,TYPE,BHTEXT,EHTEXT) ;Get a future date range. FBDATE ;Select the beginning date. N X,Y,DIR K DIROUT,DIRUT,DTOUT,DUOUT S DIR(0)="DA^"_DT_"::EFTX" S DIR("A")="Enter "_TYPE_" BEGINNING DATE AND TIME: " S DIR("B")=$$FMTE^XLFDT($$DT^XLFDT,"D") S DIR("PRE")="S X=$$DCHECK^PXRMDATE(X) K:X=-1 X" S DIR("?")="This must be a future date. For detailed help type ??" S DIR("??")=U_"D BDHELP^PXRMXDUT(.BHTEXT,TYPE)" W ! D ^DIR K DIR I $D(DIROUT) S DTOUT=1 I $D(DTOUT)!($D(DUOUT)) Q S BDATE=Y I $E(Y,6,7)="00" W $C(7)," ?? Enter exact date" G FBDATE ; FEDATE ;Select the ending date. S DIR(0)="DA^"_BDATE_"::ETFX" S DIR("A")="Enter "_TYPE_" ENDING DATE AND TIME: " S DIR("PRE")="S X=$$DCHECK^PXRMDATE(X) K:X=-1 X" S DIR("?")="This must be a future date and not before "_$$FMTE^XLFDT(BDATE,"P")_". For detailed help type ??" S DIR("??")=U_"D EDHELP^PXRMXDUT(.EHTEXT,TYPE)" D ^DIR K DIR I $D(DIROUT) S DTOUT=1 I $D(DTOUT) Q I $D(DUOUT) G FBDATE S EDATE=Y I EDATE