MAGSDOFL ;WOIFO/SF - DEX & AA Track Offline Images ; 01/31/13
;;3.0;IMAGING;**18,98,135**;Mar 19, 2002;Build 5238;Jul 17, 2013
;; Per VHA Directive 2004-038, this routine should not be modified.
;; +---------------------------------------------------------------+
;; | Property of the US Government. |
;; | No permission to copy or redistribute this software is given. |
;; | Use of unreleased versions of this software requires the user |
;; | to execute a written test agreement with the VistA Imaging |
;; | Development Office of the Department of Veterans Affairs, |
;; | telephone (301) 734-0100. |
;; | The Food and Drug Administration classifies this software as |
;; | a medical device. As such, it may not be changed in any way. |
;; | Modifications to this software may result in an adulterated |
;; | medical device under 21CFR820, the use of which is considered |
;; | to be a violation of US Federal Statutes. |
;; +---------------------------------------------------------------+
;;
Q
ENTRY ;Interactive entry here
I '$D(DUZ) W !,"Use the MAG JB OFFLINE menu option to run this application" Q
N BOLD,NORMAL,N,R
D SETUP W @IOF
LOOP ; main menu loop
D SETUP
W !!,$P($T(OPTIONS),";",3),!
S N=0 F I=1:1 S X=$P($T(OPTIONS+I),";",3,999) Q:X="" D ; list options
. I $P(X,";")="" Q
. S N=N+1 W !,?2,$J(N,2),?6,$P(X,";")
. Q
;
AGAIN ;
W !!,?2,"OPTION: " R " ",R:DTIME Q:R=""!(R="^")
I R["?" D HELP2 G AGAIN
I R?1N.N,R>0,R'>N D G LOOP
. S N=0 F I=1:1 D Q:X="" I R=N D @($P(X,";",2)),RETURN Q
. . S X=$P($T(OPTIONS+I),";",3,999) Q:X=""
. . S N=N+1
. Q
W " ??? -- Invalid option. Try again." G AGAIN
;
SETUP ;
I ^%ZOSF("OS")?1"MSM".E S IOF="#"
E D HOME^%ZIS
S U="^"
S NORMAL=$C(27)_"[0;"_"44m" ; normal blue
S BOLD=$C(27)_"[1;"_"44m" ; bold blue
Q
;
RETURN ;
D SETUP
R !!,"Push <Enter> to continue...",X:DTIME
Q
OFFLINE(MAGIN) ;Set images offline
N COUNT
ASK1 I MAGIN="" R !!,"Enter file to read offline images from: ",X:DTIME
I X="" Q
I X="^" Q
I X["?" D HELP1 G ASK1
N IOP,MAGFDA,MAGFL
I MAGIN="" S MAGIN=X
S %ZIS="",%ZIS("HFSNAME")=MAGIN,%ZIS("HFSMODE")="R",IOP="HFS"
S X="ERROR^MAGSDOFL",@^%ZOSF("TRAP")
S MAGFL=2006.033
S COUNT=0
U IO(0) W !!,"Here goes nothing...",!
D ^%ZIS
F U IO R LN:5 Q:LN["Files Listed" D
. S COUNT=COUNT+1
. S LN=$$TRIM(LN)
. I LN["Media """ S MAGPLAT=$P(LN,"""",2) U IO(0) W !,MAGPLAT
. I COUNT#50=0 U IO(0) W "."
. S LN=$$FNAME(LN) Q:LN=""
. K MAGIEN S MAGIEN="?+1,"
. S MAGFDA(MAGFL,MAGIEN,.01)=LN
. S MAGFDA(MAGFL,MAGIEN,1)=MAGPLAT
. D UPDATE^DIE("","MAGFDA","MAGIEN","MAGERR")
. Q
W !,"Done."
Q
LINE(OUT,LN,MAGPLAT) ;RPC - MAG UTIL JBOFFLN
; LN := Process the line from JB platter/media report
; MAGPLAT := platter name
; OUT := return the result
; e.g.: '0, Done'
; '-1, Error message'
;
N MAGFL,MAGIEN
S OUT(0)=0,MAGFL=2006.033 ;;JB offline file
I ($G(LN)="")!($G(MAGPLAT)="") S OUT(0)="-1,No text line value or specified platter" Q
S LN=$$TRIM(LN)
S LN=$$FNAME(LN) Q:LN=""
K MAGIEN S MAGIEN="?+1,"
S MAGFDA(MAGFL,MAGIEN,.01)=LN
S MAGFDA(MAGFL,MAGIEN,1)=MAGPLAT
D UPDATE^DIE("","MAGFDA","MAGIEN","MAGERR")
S OUT(0)="0,Done"
Q
FNAME(LN) ;Find img file name
N XX ;OTG 4x or 5x
I LN["\" D Q XX
. F N=1:1 S XX=$P(LN,"\",N) Q:XX="" I XX?.E1"."2.5AN S LN=XX Q
;OTG 3x
I $P(LN," ",1)'?.E1"."2.5AN Q ""
S LN=$P(LN," ")
Q LN
ONLINE(MAGPLAT) ;Set images back online
;
ASK I MAGPLAT="" U IO(0) R !!,"Enter the name of the platter being inserted: ",X:DTIME
I X="" Q
I X="^" Q
I X["?" D HELP G ASK
N MAGENT
S MAGPLAT=X
I '$D(^MAGQUEUE(2006.033,"C",MAGPLAT)) W " Platter not on file..." Q
S DIK="^MAGQUEUE(2006.033,"
S MAGENT=""
F S MAGENT=$O(^MAGQUEUE(2006.033,"C",MAGPLAT,MAGENT)) Q:'MAGENT D
. S DA=MAGENT
. D ^DIK
. I $D(Y) U IO(0) W "."
. E U IO(0) W !,"Problem deleting entry# "_MAGENT
U IO(0) W !,"Done."
Q
HELP ;List offline platters
U IO(0) W !,"Do you want to see a list of all offline platters? " R X:60
I "?"[$E(X) W !!,"Answer ""yes"" to see a list of platters currently marked offline"
I "?"[$E(X) W !,"Answer ""no"" to return",! G HELP
I "Yy"'[$E(X) Q
LISTP S MAGPLAT=""
F S MAGPLAT=$O(^MAGQUEUE(2006.033,"C",MAGPLAT)) D Q:MAGPLAT=""
. U IO(0) W !,MAGPLAT
Q
LISTOFL(OUT) ;RPC - MAG UTIL LSTOFLJB ;LIST OFFLINE JB PLATTER(S) ;;*98
N MAGPLAT,CNT S MAGPLAT="",OUT(1)="0"
F CNT=1:1 S MAGPLAT=$O(^MAGQUEUE(2006.033,"C",MAGPLAT)) Q:MAGPLAT="" S OUT(CNT)=MAGPLAT
Q
BKONL(OUT,MAGPLAT) ;RPC - MAG UTIL BKONLJB ;Put images back online (Insert Jukebox Platter)
N DIK,CNT,DA,Y
S OUT(1)="0"
I $G(MAGPLAT)="" S OUT(1)="-1,No JB Platter specified" Q
I $O(^MAGQUEUE(2006.033,"C",MAGPLAT,0))="" S OUT(1)="-1,Platter not on file 2006.033 -"_MAGPLAT Q
S DIK="^MAGQUEUE(2006.033,",MAGENT=""
F CNT=0:1 S MAGENT=$O(^MAGQUEUE(2006.033,"C",MAGPLAT,MAGENT)) Q:'MAGENT D
. S DA=MAGENT D ^DIK
I $D(Y) S OUT(1)="0,Done "_CNT
Q
GROUP ;Remove platters in group
N COUNT,MAGPLAT,PLAT,X,TOTAL,MAGIEN,CNT,IOP,MAGFDA,MAGFL,POP
ASK3 R !!,"Enter 'DIR' file to read offline platter TXT from: ",X:$G(DTIME)
I X=""!(X="^") Q
I X["?" D HELP3 G ASK3
S MAGIN=X ;DIR filename
S %ZIS="",%ZIS("HFSNAME")=MAGIN,%ZIS("HFSMODE")="R",IOP="HFS"
S X="ERROR^MAGSDOFL",@^%ZOSF("TRAP")
D ^%ZIS
F U IO R MAGPLAT:30 Q:($G(MAGPLAT)="")!($G(MAGPLAT)["~end") I $L(MAGPLAT) S MAGPLAT(MAGPLAT)=0 U IO(0) W "|"
D ^%ZISC
S MAGFL=2006.033
U IO(0) W !!,"Here goes nothing...",!,"50 per '.'",!
S PLAT="" F CNT=0:1 S PLAT=$O(MAGPLAT(PLAT)) Q:PLAT="" U IO(0) W !,PLAT D
. S COUNT=0,%ZIS="",%ZIS("HFSNAME")=PLAT,%ZIS("HFSMODE")="R",IOP="HFS"
. S X="ERROR^MAGSDOFL",@^%ZOSF("TRAP")
. D ^%ZIS I POP W !,"Sorry, ",PLAT," not found, try later.",! Q
. F U IO R LN:5 D
. . S COUNT=COUNT+1,TOTAL=$G(TOTAL)+1
. . S LN=$$TRIM(LN)
. . I LN["Media """ S MAGPLAT=$P(LN,"""",2) U IO(0) W !,MAGPLAT
. . I COUNT#50=0 U IO(0) W "."
. . S LN=$$FNAME(LN) Q:LN=""
. . K MAGIEN S MAGIEN="?+1,"
. . S MAGFDA(MAGFL,MAGIEN,.01)=LN
. . S MAGFDA(MAGFL,MAGIEN,1)=MAGPLAT
. . D UPDATE^DIE("","MAGFDA","MAGIEN","MAGERR")
. . Q
. D ^%ZISC ;cls media report
. Q
U IO(0) W !,"Done (",CNT," platter(s), total files ",TOTAL," were marked offline.)",!
Q
HELP1 ;Help for offline
W !,"Enter the name of the file created by the jukebox media file report"
Q
HELP2 ;Help for OPTION prompt
W !,"Select option 1 if you are marking DEX images offline"
W !,"Select option 2 if you are marking images online"
W !,"Select option 3 if you want the listing of off-line platter(s)"
W !,"Select option 4 if you are taking the group of platters off-line"
W !,"Select option 5 if you are marking Archive Appliance (AA) images offline"
W !,"Type ""^"" to quit"
Q
HELP3 ;Help for GROUP platters TXT
W !,"Enter the full file name that is grouped by the jukebox media TXT file report",!
W !,"For example: you do 'DIR JB*.TXT /B /S > [USER]DIR.TXT' ,append '~end' at end of file",!
W !,"Then use [USER]DIR.TXT as source file",!
Q
;
TRIM(X) ;
N I,J
F I=1:1:$L(X) Q:$E(X,I)'=" "
F J=$L(X):-1:I Q:$E(X,J)'=" "
Q $E(X,I,J)
ERROR ;Trap Errors Here
D ^%ZISC
Q
OPTIONS ; Offline Image Menu
;;Take DEX images offline (Remove Jukebox Platter);OFFLINE("")
;;Put images back online (Insert Jukebox Platter);ONLINE("")
;;Take images offline (Group platters);GROUP
;;List current offline Jukebox Platter;LISTP
;;Take 'AA' Archive Appliance images offline (Remove Jukebox Platter);EN^MAGSDOFF
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HMAGSDOFL 7729 printed Dec 13, 2024@02:08:18 Page 2
MAGSDOFL ;WOIFO/SF - DEX & AA Track Offline Images ; 01/31/13
+1 ;;3.0;IMAGING;**18,98,135**;Mar 19, 2002;Build 5238;Jul 17, 2013
+2 ;; Per VHA Directive 2004-038, this routine should not be modified.
+3 ;; +---------------------------------------------------------------+
+4 ;; | Property of the US Government. |
+5 ;; | No permission to copy or redistribute this software is given. |
+6 ;; | Use of unreleased versions of this software requires the user |
+7 ;; | to execute a written test agreement with the VistA Imaging |
+8 ;; | Development Office of the Department of Veterans Affairs, |
+9 ;; | telephone (301) 734-0100. |
+10 ;; | The Food and Drug Administration classifies this software as |
+11 ;; | a medical device. As such, it may not be changed in any way. |
+12 ;; | Modifications to this software may result in an adulterated |
+13 ;; | medical device under 21CFR820, the use of which is considered |
+14 ;; | to be a violation of US Federal Statutes. |
+15 ;; +---------------------------------------------------------------+
+16 ;;
+17 QUIT
ENTRY ;Interactive entry here
+1 IF '$DATA(DUZ)
WRITE !,"Use the MAG JB OFFLINE menu option to run this application"
QUIT
+2 NEW BOLD,NORMAL,N,R
+3 DO SETUP
WRITE @IOF
LOOP ; main menu loop
+1 DO SETUP
+2 WRITE !!,$PIECE($TEXT(OPTIONS),";",3),!
+3 ; list options
SET N=0
FOR I=1:1
SET X=$PIECE($TEXT(OPTIONS+I),";",3,999)
if X=""
QUIT
Begin DoDot:1
+4 IF $PIECE(X,";")=""
QUIT
+5 SET N=N+1
WRITE !,?2,$JUSTIFY(N,2),?6,$PIECE(X,";")
+6 QUIT
End DoDot:1
+7 ;
AGAIN ;
+1 WRITE !!,?2,"OPTION: "
READ " ",R:DTIME
if R=""!(R="^")
QUIT
+2 IF R["?"
DO HELP2
GOTO AGAIN
+3 IF R?1N.N
IF R>0
IF R'>N
Begin DoDot:1
+4 SET N=0
FOR I=1:1
Begin DoDot:2
+5 SET X=$PIECE($TEXT(OPTIONS+I),";",3,999)
if X=""
QUIT
+6 SET N=N+1
End DoDot:2
if X=""
QUIT
IF R=N
DO @($PIECE(X,";",2))
DO RETURN
QUIT
+7 QUIT
End DoDot:1
GOTO LOOP
+8 WRITE " ??? -- Invalid option. Try again."
GOTO AGAIN
+9 ;
SETUP ;
+1 IF ^%ZOSF("OS")?1"MSM".E
SET IOF="#"
+2 IF '$TEST
DO HOME^%ZIS
+3 SET U="^"
+4 ; normal blue
SET NORMAL=$CHAR(27)_"[0;"_"44m"
+5 ; bold blue
SET BOLD=$CHAR(27)_"[1;"_"44m"
+6 QUIT
+7 ;
RETURN ;
+1 DO SETUP
+2 READ !!,"Push <Enter> to continue...",X:DTIME
+3 QUIT
OFFLINE(MAGIN) ;Set images offline
+1 NEW COUNT
ASK1 IF MAGIN=""
READ !!,"Enter file to read offline images from: ",X:DTIME
+1 IF X=""
QUIT
+2 IF X="^"
QUIT
+3 IF X["?"
DO HELP1
GOTO ASK1
+4 NEW IOP,MAGFDA,MAGFL
+5 IF MAGIN=""
SET MAGIN=X
+6 SET %ZIS=""
SET %ZIS("HFSNAME")=MAGIN
SET %ZIS("HFSMODE")="R"
SET IOP="HFS"
+7 SET X="ERROR^MAGSDOFL"
SET @^%ZOSF("TRAP")
+8 SET MAGFL=2006.033
+9 SET COUNT=0
+10 USE IO(0)
WRITE !!,"Here goes nothing...",!
+11 DO ^%ZIS
+12 FOR
USE IO
READ LN:5
if LN["Files Listed"
QUIT
Begin DoDot:1
+13 SET COUNT=COUNT+1
+14 SET LN=$$TRIM(LN)
+15 IF LN["Media """
SET MAGPLAT=$PIECE(LN,"""",2)
USE IO(0)
WRITE !,MAGPLAT
+16 IF COUNT#50=0
USE IO(0)
WRITE "."
+17 SET LN=$$FNAME(LN)
if LN=""
QUIT
+18 KILL MAGIEN
SET MAGIEN="?+1,"
+19 SET MAGFDA(MAGFL,MAGIEN,.01)=LN
+20 SET MAGFDA(MAGFL,MAGIEN,1)=MAGPLAT
+21 DO UPDATE^DIE("","MAGFDA","MAGIEN","MAGERR")
+22 QUIT
End DoDot:1
+23 WRITE !,"Done."
+24 QUIT
LINE(OUT,LN,MAGPLAT) ;RPC - MAG UTIL JBOFFLN
+1 ; LN := Process the line from JB platter/media report
+2 ; MAGPLAT := platter name
+3 ; OUT := return the result
+4 ; e.g.: '0, Done'
+5 ; '-1, Error message'
+6 ;
+7 NEW MAGFL,MAGIEN
+8 ;;JB offline file
SET OUT(0)=0
SET MAGFL=2006.033
+9 IF ($GET(LN)="")!($GET(MAGPLAT)="")
SET OUT(0)="-1,No text line value or specified platter"
QUIT
+10 SET LN=$$TRIM(LN)
+11 SET LN=$$FNAME(LN)
if LN=""
QUIT
+12 KILL MAGIEN
SET MAGIEN="?+1,"
+13 SET MAGFDA(MAGFL,MAGIEN,.01)=LN
+14 SET MAGFDA(MAGFL,MAGIEN,1)=MAGPLAT
+15 DO UPDATE^DIE("","MAGFDA","MAGIEN","MAGERR")
+16 SET OUT(0)="0,Done"
+17 QUIT
FNAME(LN) ;Find img file name
+1 ;OTG 4x or 5x
NEW XX
+2 IF LN["\"
Begin DoDot:1
+3 FOR N=1:1
SET XX=$PIECE(LN,"\",N)
if XX=""
QUIT
IF XX?.E1"."2.5AN
SET LN=XX
QUIT
End DoDot:1
QUIT XX
+4 ;OTG 3x
+5 IF $PIECE(LN," ",1)'?.E1"."2.5AN
QUIT ""
+6 SET LN=$PIECE(LN," ")
+7 QUIT LN
ONLINE(MAGPLAT) ;Set images back online
+1 ;
ASK IF MAGPLAT=""
USE IO(0)
READ !!,"Enter the name of the platter being inserted: ",X:DTIME
+1 IF X=""
QUIT
+2 IF X="^"
QUIT
+3 IF X["?"
DO HELP
GOTO ASK
+4 NEW MAGENT
+5 SET MAGPLAT=X
+6 IF '$DATA(^MAGQUEUE(2006.033,"C",MAGPLAT))
WRITE " Platter not on file..."
QUIT
+7 SET DIK="^MAGQUEUE(2006.033,"
+8 SET MAGENT=""
+9 FOR
SET MAGENT=$ORDER(^MAGQUEUE(2006.033,"C",MAGPLAT,MAGENT))
if 'MAGENT
QUIT
Begin DoDot:1
+10 SET DA=MAGENT
+11 DO ^DIK
+12 IF $DATA(Y)
USE IO(0)
WRITE "."
+13 IF '$TEST
USE IO(0)
WRITE !,"Problem deleting entry# "_MAGENT
End DoDot:1
+14 USE IO(0)
WRITE !,"Done."
+15 QUIT
HELP ;List offline platters
+1 USE IO(0)
WRITE !,"Do you want to see a list of all offline platters? "
READ X:60
+2 IF "?"[$EXTRACT(X)
WRITE !!,"Answer ""yes"" to see a list of platters currently marked offline"
+3 IF "?"[$EXTRACT(X)
WRITE !,"Answer ""no"" to return",!
GOTO HELP
+4 IF "Yy"'[$EXTRACT(X)
QUIT
LISTP SET MAGPLAT=""
+1 FOR
SET MAGPLAT=$ORDER(^MAGQUEUE(2006.033,"C",MAGPLAT))
Begin DoDot:1
+2 USE IO(0)
WRITE !,MAGPLAT
End DoDot:1
if MAGPLAT=""
QUIT
+3 QUIT
LISTOFL(OUT) ;RPC - MAG UTIL LSTOFLJB ;LIST OFFLINE JB PLATTER(S) ;;*98
+1 NEW MAGPLAT,CNT
SET MAGPLAT=""
SET OUT(1)="0"
+2 FOR CNT=1:1
SET MAGPLAT=$ORDER(^MAGQUEUE(2006.033,"C",MAGPLAT))
if MAGPLAT=""
QUIT
SET OUT(CNT)=MAGPLAT
+3 QUIT
BKONL(OUT,MAGPLAT) ;RPC - MAG UTIL BKONLJB ;Put images back online (Insert Jukebox Platter)
+1 NEW DIK,CNT,DA,Y
+2 SET OUT(1)="0"
+3 IF $GET(MAGPLAT)=""
SET OUT(1)="-1,No JB Platter specified"
QUIT
+4 IF $ORDER(^MAGQUEUE(2006.033,"C",MAGPLAT,0))=""
SET OUT(1)="-1,Platter not on file 2006.033 -"_MAGPLAT
QUIT
+5 SET DIK="^MAGQUEUE(2006.033,"
SET MAGENT=""
+6 FOR CNT=0:1
SET MAGENT=$ORDER(^MAGQUEUE(2006.033,"C",MAGPLAT,MAGENT))
if 'MAGENT
QUIT
Begin DoDot:1
+7 SET DA=MAGENT
DO ^DIK
End DoDot:1
+8 IF $DATA(Y)
SET OUT(1)="0,Done "_CNT
+9 QUIT
GROUP ;Remove platters in group
+1 NEW COUNT,MAGPLAT,PLAT,X,TOTAL,MAGIEN,CNT,IOP,MAGFDA,MAGFL,POP
ASK3 READ !!,"Enter 'DIR' file to read offline platter TXT from: ",X:$GET(DTIME)
+1 IF X=""!(X="^")
QUIT
+2 IF X["?"
DO HELP3
GOTO ASK3
+3 ;DIR filename
SET MAGIN=X
+4 SET %ZIS=""
SET %ZIS("HFSNAME")=MAGIN
SET %ZIS("HFSMODE")="R"
SET IOP="HFS"
+5 SET X="ERROR^MAGSDOFL"
SET @^%ZOSF("TRAP")
+6 DO ^%ZIS
+7 FOR
USE IO
READ MAGPLAT:30
if ($GET(MAGPLAT)="")!($GET(MAGPLAT)["~end")
QUIT
IF $LENGTH(MAGPLAT)
SET MAGPLAT(MAGPLAT)=0
USE IO(0)
WRITE "|"
+8 DO ^%ZISC
+9 SET MAGFL=2006.033
+10 USE IO(0)
WRITE !!,"Here goes nothing...",!,"50 per '.'",!
+11 SET PLAT=""
FOR CNT=0:1
SET PLAT=$ORDER(MAGPLAT(PLAT))
if PLAT=""
QUIT
USE IO(0)
WRITE !,PLAT
Begin DoDot:1
+12 SET COUNT=0
SET %ZIS=""
SET %ZIS("HFSNAME")=PLAT
SET %ZIS("HFSMODE")="R"
SET IOP="HFS"
+13 SET X="ERROR^MAGSDOFL"
SET @^%ZOSF("TRAP")
+14 DO ^%ZIS
IF POP
WRITE !,"Sorry, ",PLAT," not found, try later.",!
QUIT
+15 FOR
USE IO
READ LN:5
Begin DoDot:2
+16 SET COUNT=COUNT+1
SET TOTAL=$GET(TOTAL)+1
+17 SET LN=$$TRIM(LN)
+18 IF LN["Media """
SET MAGPLAT=$PIECE(LN,"""",2)
USE IO(0)
WRITE !,MAGPLAT
+19 IF COUNT#50=0
USE IO(0)
WRITE "."
+20 SET LN=$$FNAME(LN)
if LN=""
QUIT
+21 KILL MAGIEN
SET MAGIEN="?+1,"
+22 SET MAGFDA(MAGFL,MAGIEN,.01)=LN
+23 SET MAGFDA(MAGFL,MAGIEN,1)=MAGPLAT
+24 DO UPDATE^DIE("","MAGFDA","MAGIEN","MAGERR")
+25 QUIT
End DoDot:2
+26 ;cls media report
DO ^%ZISC
+27 QUIT
End DoDot:1
+28 USE IO(0)
WRITE !,"Done (",CNT," platter(s), total files ",TOTAL," were marked offline.)",!
+29 QUIT
HELP1 ;Help for offline
+1 WRITE !,"Enter the name of the file created by the jukebox media file report"
+2 QUIT
HELP2 ;Help for OPTION prompt
+1 WRITE !,"Select option 1 if you are marking DEX images offline"
+2 WRITE !,"Select option 2 if you are marking images online"
+3 WRITE !,"Select option 3 if you want the listing of off-line platter(s)"
+4 WRITE !,"Select option 4 if you are taking the group of platters off-line"
+5 WRITE !,"Select option 5 if you are marking Archive Appliance (AA) images offline"
+6 WRITE !,"Type ""^"" to quit"
+7 QUIT
HELP3 ;Help for GROUP platters TXT
+1 WRITE !,"Enter the full file name that is grouped by the jukebox media TXT file report",!
+2 WRITE !,"For example: you do 'DIR JB*.TXT /B /S > [USER]DIR.TXT' ,append '~end' at end of file",!
+3 WRITE !,"Then use [USER]DIR.TXT as source file",!
+4 QUIT
+5 ;
TRIM(X) ;
+1 NEW I,J
+2 FOR I=1:1:$LENGTH(X)
if $EXTRACT(X,I)'=" "
QUIT
+3 FOR J=$LENGTH(X):-1:I
if $EXTRACT(X,J)'=" "
QUIT
+4 QUIT $EXTRACT(X,I,J)
ERROR ;Trap Errors Here
+1 DO ^%ZISC
+2 QUIT
OPTIONS ; Offline Image Menu
+1 ;;Take DEX images offline (Remove Jukebox Platter);OFFLINE("")
+2 ;;Put images back online (Insert Jukebox Platter);ONLINE("")
+3 ;;Take images offline (Group platters);GROUP
+4 ;;List current offline Jukebox Platter;LISTP
+5 ;;Take 'AA' Archive Appliance images offline (Remove Jukebox Platter);EN^MAGSDOFF