Changeset 1569 for smart/trunk/p/C0SUTIL.m
- Timestamp:
- Oct 11, 2012, 1:42:56 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
smart/trunk/p/C0SUTIL.m
r1540 r1569 1 C0SUTIL 2 ;;1.0;VISTA SMART CONTAINER;;Sep 26, 2012;Build 23 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 SPDATE(ZDATE) 23 24 25 26 27 28 29 30 31 32 33 34 1 C0SUTIL ; GPL - Smart Processing Utilities ;2/22/12 17:05 2 ;;0.1;C0S;nopatch;noreleasedate;Build 2 3 ;Copyright 2012 George Lilly. Licensed under the terms of the GNU 4 ;General Public License See attached copy of the License. 5 ; 6 ;This program is free software; you can redistribute it and/or modify 7 ;it under the terms of the GNU General Public License as published by 8 ;the Free Software Foundation; either version 2 of the License, or 9 ;(at your option) any later version. 10 ; 11 ;This program is distributed in the hope that it will be useful, 12 ;but WITHOUT ANY WARRANTY; without even the implied warranty of 13 ;MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 ;GNU General Public License for more details. 15 ; 16 ;You should have received a copy of the GNU General Public License along 17 ;with this program; if not, write to the Free Software Foundation, Inc., 18 ;51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 19 ; 20 Q 21 ; 22 SPDATE(ZDATE) ; extrinsic which returns the Smart date format yyyy-mm-dd 23 ; ZDATE is a fileman format date 24 N TMPDT 25 S TMPDT=$$FMTE^XLFDT(ZDATE,"7D") ; ordered date 26 S TMPDT=$TR(TMPDT,"/","-") ; change slashes to hyphens 27 I TMPDT="" S TMPDT="UNKNOWN" 28 N Z2,Z3 29 S Z2=$P(TMPDT,"-",2) 30 S Z3=$P(TMPDT,"-",3) 31 I $L(Z2)=1 S $P(TMPDT,"-",2)="0"_Z2 32 I $L(Z3)=1 S $P(TMPDT,"-",3)="0"_Z3 33 Q TMPDT 34 ;
Note:
See TracChangeset
for help on using the changeset viewer.