Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: DIPZ0

DIPZ0.m

Go to the documentation of this file.
  1. DIPZ0 ;SFISC/TKW-COMPILE PRINT TEMPLATES ;19JAN2010
  1. ;;22.2;VA FileMan;;Jan 05, 2016;Build 42
  1. ;;Per VA Directive 6402, this routine should not be modified.
  1. ;;Submitted to OSEHRA 5 January 2015 by the VISTA Expertise Network.
  1. ;;Based on Medsphere Systems Corporation's MSC FileMan 1051.
  1. ;;Licensed under the terms of the Apache License, Version 2.0.
  1. ;
  1. SIZ(DITYP) ;PROMPT FOR SIZE OF COMPILED ROUTINE
  1. ;PARAMETER DITYP CONTAINS A NUMBER IN DIALOG FILE POINTING TO EITHER
  1. ;TEXT FOR A TEMPLATE TYPE, OR TO THE TEXT 'CROSS-REFERENCES'.
  1. N %,DIR
  1. S %=$G(^DD("ROU")) S:'% %=$P($G(^DD("OS",DISYS,0)),U,4) S:'% %=5000
  1. S DIR(0)="N^2400:"_%_":0",DIR("B")=%,DIR("A")=$$EZBLD^DIALOG(8027)
  1. K % S %(1)=$$EZBLD^DIALOG(DITYP) D BLD^DIALOG(9002,.%,"","DIR(""?"")")
  1. D ^DIR Q
  1. ;
  1. RNM(DITYP) ;PROMPT FOR COMPILED ROUTINE NAME
  1. ;PARAMETER SAME AS FOR SIZ.
  1. N %,DIR,DIRNM
  1. S DIRNM="" D
  1. .I DITYP<8036 S DIRNM=$G(@(DIC_DIPZ_",""ROUOLD"")")),DIRNM(1)=$G(@(DIC_DIPZ_",""ROU"")"))
  1. .E S DIRNM=$G(@("^DD("_DIPZ_",0,""DIKOLD"")")),DIRNM(1)=$G(@("^DD("_DIPZ_",0,""DIK"")")) S:DIRNM="" DIRNM=DIRNM(1)
  1. .Q
  1. I DIRNM(1)]"" S DIR(0)="Y",DIR("B")="NO" D D ^DIR K DIR Q:$D(DIRUT) I Y D UNC Q
  1. .K % S %(1)=$$EZBLD^DIALOG(DITYP),%(2)=DIRNM(1)
  1. .D BLD^DIALOG(8028,.%,"","DIR(""A"")")
  1. .K %(2) D BLD^DIALOG(9004,.%,"","DIR(""?"")")
  1. .Q
  1. S %=7 ;S:DITYP=8036 %=6
  1. S DIR(0)="F^3:"_%_"^K:X'?1U.NU&(X'?1""%""1U.NU)!(X?1""DI"".E) X" S:DIRNM]"" DIR("B")=DIRNM
  1. D BLD^DIALOG(8001,"","","DIR(""A"")"),BLD^DIALOG(9006,%,"","DIR(""?"")")
  1. D ^DIR K DIR Q:$D(DIRUT)!(X="")
  1. I $L(X)>6 D
  1. .N A,% D BLD^DIALOG(8031,"","","A") W $C(7),! F %=0:0 S %=$O(A(%)) Q:'% W A(%),!
  1. .W ! Q
  1. I $$ROUEXIST^DILIBF(X) K % S %(1)=U_X D BLD^DIALOG(8016,.%,"","DIR") W $C(7),!?5,DIR K DIR
  1. Q
  1. UNC ;UNCOMPILE TEMPLATES/CROSS-REFS
  1. N %,DIR,DIPZ0 I DITYP<8036 K @(DIC_DIPZ_",""ROU"")") S DIPZ0=$G(^("ROUOLD")) D
  1. . I DITYP=8033 D UNCAF^DIEZ(DIPZ)
  1. .D DELETROU^DIEZ(DIPZ0)
  1. E S X=DIPZ D A^DIU21
  1. S %(1)=$$EZBLD^DIALOG(DITYP) D BLD^DIALOG(8026,.%,"","DIR(""A"")") ;'IS NOW UNCOMPILED'
  1. W $C(7),!!,DIR("A")
  1. S X="" Q
  1. ;
  1. ;DIALOG #8001 'Routine Name'
  1. ; #8016 'Note that...is already in the routine directory'
  1. ; #8027 'Maximum routine size on this computer...'
  1. ; #8028 '...currently compiled under namespace...UNCOMPILE...'
  1. ; #8031 'WARNING!! Since the namespace...routine...so long...'
  1. ; #8033 'Input template'
  1. ; #8034 'Print Template'
  1. ; #8036 'Cross-Reference(s)'
  1. ; #9002 'This number will be used to determine how large...'
  1. ; #9004 'Answer YES to UNCOMPILE the ...'
  1. ; #9006 'Enter a valid MUMPS routine name...'