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

DVBAUTL1.m

Go to the documentation of this file.
  1. DVBAUTL1 ;ALB/JLU;UTILITY ROUTINE;11/8/94
  1. ;;2.7;AMIE;;Apr 10, 1995
  1. ;
  1. STATION(DFN) ;
  1. ;this function call returns the station number of the patient in the
  1. ;parameter or -1 if no station number.
  1. ;
  1. N X
  1. I '$D(^DPT(DFN,.31)) Q -1
  1. S X=$P(^DPT(DFN,.31),U,4)
  1. I X="" Q -1
  1. I '$D(^DIC(4,X,99)) Q -1
  1. S X=$P(^DIC(4,X,99),U,1)
  1. I X<1 Q -1
  1. Q X
  1. ;
  1. EXIT ;this entry point is called from the DVBAPOST routine. It is used as
  1. ;the kill statment at the end of the post init.
  1. ;
  1. I $D(V3) K CNT,LP1,V3,XMZ,XMY(DUZ),XMY(.5),XMSUB,XMDUZ
  1. K STOP
  1. Q
  1. ;
  1. SET1 ;sets the parameter file node to be used in the post init Keyword
  1. ;population.
  1. I '$D(CNT) S CNT=1
  1. I $D(^DVB(396.1,0)) DO
  1. .N DVBA
  1. .S DVBA=$$IFNPAR^DVBAUTL3()
  1. .I DVBA=0 DO
  1. ..S DIC="^DVB(396.1,",DIC(0)="L"
  1. ..K DD,D0
  1. ..S X=$P(^DG(40.8,$$PRIM^VASITE,0),U,1)
  1. ..D FILE^DICN
  1. ..S DVBA=$S(Y=-1:0,1:+Y)
  1. ..K DIC,DD,D0,Y,X
  1. ..Q
  1. .S ^DVB(396.1,DVBA,"POST")="DVBA;ADVB;DVBB;ADVB"
  1. .S:$P(^DVB(396.1,DVBA,0),U,15)']"" $P(^(0),U,15)=1
  1. .S:$P(^DVB(396.1,DVBA,0),U,18)']"" $P(^(0),U,18)=1
  1. .S:$P(^DVB(396.1,DVBA,0),U,19)']"" $P(^(0),U,19)=1
  1. Q