XWBFM ;SFISC/VYD - Broker FileMan connectivity ;08/14/95 16:31
;;1.1;RPC BROKER;;Mar 28, 1997
FIELDLST(RESULT,FNUM) ;retrieve a list of top-level fields of passed file
;and return it in RESLUT
;**** Note: requires FileMan v 21 with NEW DD RETRIEVER VER 1.0 patch
N %
D FILE^DID(FNUM,"T","FIELDS","^TMP($J)","JUNK")
S %="" F S %=$O(^TMP($J,"FIELDS",%)) Q:%="" D
. S RESULT(%)=$P(^(%),U)_" ["_$P(^(%),U,2)_"]"
K ^TMP($J)
Q
;
FILELIST(RESULT,START) ;retrieve a list and return it in RESLUT
N %
D LIST^DIC(1,"","","P","","",START)
S %=0 F S %=$O(^TMP("DILIST",$J,%)) Q:%="" D
. S RESULT(%)=$P(^(%,0),U)_" ["_$P(^(0),U,2)_"]"
K ^TMP("DILIST",$J) ;clean up
Q
;
APILIST(RESULT,START) ;retrieve a list and return it in RESLUT
N %
D LIST^DIC(8994,"",".02;.03","P","","",START)
S %=0 F S %=$O(^TMP("DILIST",$J,%)) Q:%="" D
. S RESULT(%)=$P(^(%,0),U)_" ["_$P(^(0),U,3,4)_"]"
K ^TMP("DILIST",$J) ;clean up
Q
;
FILECHK(RESULT,FNAME) ;checks if the FNAME file exists. If found, return IEN
S RESULT=$$FIND1^DIC(1,"","O",FNAME)
Q
XWBFM ;SFISC/VYD - Broker FileMan connectivity ;08/14/95 16:31
+1 ;;1.1;RPC BROKER;;Mar 28, 1997
FIELDLST(RESULT,FNUM) ;retrieve a list of top-level fields of passed file
+1 ;and return it in RESLUT
+2 ;**** Note: requires FileMan v 21 with NEW DD RETRIEVER VER 1.0 patch
+3 NEW %
+4 DO FILE^DID(FNUM,"T","FIELDS","^TMP($J)","JUNK")
+5 SET %=""
FOR
SET %=$ORDER(^TMP($JOB,"FIELDS",%))
IF %=""
QUIT
Begin DoDot:1
+6 SET RESULT(%)=$PIECE(^(%),U)_" ["_$PIECE(^(%),U,2)_"]"
End DoDot:1
+7 KILL ^TMP($JOB)
+8 QUIT
+9 ;
FILELIST(RESULT,START) ;retrieve a list and return it in RESLUT
+1 NEW %
+2 DO LIST^DIC(1,"","","P","","",START)
+3 SET %=0
FOR
SET %=$ORDER(^TMP("DILIST",$JOB,%))
IF %=""
QUIT
Begin DoDot:1
+4 SET RESULT(%)=$PIECE(^(%,0),U)_" ["_$PIECE(^(0),U,2)_"]"
End DoDot:1
+5 ;clean up
KILL ^TMP("DILIST",$JOB)
+6 QUIT
+7 ;
APILIST(RESULT,START) ;retrieve a list and return it in RESLUT
+1 NEW %
+2 DO LIST^DIC(8994,"",".02;.03","P","","",START)
+3 SET %=0
FOR
SET %=$ORDER(^TMP("DILIST",$JOB,%))
IF %=""
QUIT
Begin DoDot:1
+4 SET RESULT(%)=$PIECE(^(%,0),U)_" ["_$PIECE(^(0),U,3,4)_"]"
End DoDot:1
+5 ;clean up
KILL ^TMP("DILIST",$JOB)
+6 QUIT
+7 ;
FILECHK(RESULT,FNAME) ;checks if the FNAME file exists. If found, return IEN
+1 SET RESULT=$$FIND1^DIC(1,"","O",FNAME)
+2 QUIT