C0CRPMS ; CCDCCR/GPL - CCR/CCD PROCESSING FOR RPMS ;1/14/09 14:33 ;;0.1;CCDCCR;;JUL 16,2008;Build 7 ;Copyright 2008 WorldVistA. Licensed under the terms of the GNU ;General Public License See attached copy of the License. ; ;This program is free software; you can redistribute it and/or modify ;it under the terms of the GNU General Public License as published by ;the Free Software Foundation; either version 2 of the License, or ;(at your option) any later version. ; ;This program is distributed in the hope that it will be useful, ;but WITHOUT ANY WARRANTY; without even the implied warranty of ;MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;GNU General Public License for more details. ; ;You should have received a copy of the GNU General Public License along ;with this program; if not, write to the Free Software Foundation, Inc., ;51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. ; W "NO ENTRY FROM TOP",! Q ; DISPLAY ; RUN THE PCC DISPLAY ROUTINE D ^APCDDISP Q ; VTYPES ; D GETN2^C0CRNF("G1",9999999.07) ZWR G1 Q ; VISITS(C0CDFN,C0CCNT) ;LIST VISIT DATES FOR PATIENT DFN ; C0CCNT IS A LIMIT ON HOW MANY VISITS TO DISPLAY ; DEFAULTS TO ALL I '$D(C0CCNT) S C0CCNT=999999999 N G,GN S G="" S GN=0 F S G=$O(^AUPNVSIT("AA",C0CDFN,G)) Q:(G="")!(GN>C0CCNT) D ; . S GN=GN+1 . W $$FMDTOUTC^C0CUTIL(9999999-G),! Q ; VISITS2(C0CDFN,C0CCNT) ;SECOND VERSION USING NEXTV ; N C0CG,GN S C0CG="" S GN=0 I '$D(C0CCNT) S C0CCNT=99999999 F S C0CG=$$NEXTV(C0CDFN,C0CG) Q:(C0CG="")!(GN'