 REM -- H2XZPW.BAT - 31.9 PGO/PAASCHB&WUNDERL(OQX) INTFC - .....2010JUN01VM
@ECHO Off
 REM -- COPYRIGHT (C) 1997-2010 H.W.PETER, WUPPERTAL .DE --
 REM -- COPYRIGHT (C) 1997-2010 PETER+GEISENDORF GMBH, SPROCKHOEVEL .DE --
 REM -- \\UFN=OK, 2008AUG01PE
 REM -- SYS=142/3Y

 REM -- EPCSENSE=!

 REM 6789.123456789.123456789.123456789.123456789.123456789.123456789.12345
 REM ----------------------------------------------------------------------

 IF "%1"=="OQX" GOTO OQX
 IF "%1"=="FT"  GOTO OQX

ECHO ----------------------------------------------------------
ECHO %0:
ECHO INVALID CONTEXT CALL
ECHO UNGUELTIGER AUFRUF
ECHO ----------------------------------------------------------
ECHO %0 %1 %2 %3 %4 %5 %6 %7 %8 %9
PAUSE
GOTO ENDUP

REM 
REM -- H2XZPW.BAT - OQX order queue transfer to P&W --

 REM 6789.123456789.123456789.123456789.123456789.123456789.123456789.12345
 REM ----------------------------------------------------------------------

:OQX
rem -- %0=H2XZPW %1=OQX/FT *%2=homedisk *%3=homepath --
rem -- %4=OQ*.ZPW file id -- %5=HDLRNR not used 2002MAY03PE --

:OQX2
rem -- create valid directory entry for data export --
IF     EXIST C:\PGEXPORT\*.*      GOTO OQX20
IF     EXIST C:\PGEXPORT\NUL:     GOTO OQX20
IF     EXIST C:\PGEXPORT\NUL      GOTO OQX20
MD           C:\PGEXPORT
:OQX20
CLS

rem -- post file(s) to transfer --
:OQX4
IF     EXIST OQ*.ZPW  GOTO OQX42
ECHO -------------------------------------------------
ECHO -- HINWEIS: 
ECHO -- Es stehen keine NEUEN Order-Bestaende zur
ECHO -- Uebertragung zur Verfuegung.
ECHO --
GOTO OQX46

:OQX42
IF     EXIST C:\PGEXPORT\ORDZPW.CSV  DEL C:\PGEXPORT\ORDZPW.CSV
FOR %%A IN  (OQ*.ZPW)     DO TYPE %%A >> C:\PGEXPORT\ORDZPW.CSV
DEL          OQ*.ZPW
GOTO OQX46

:OQX46
DIR          C:\PGEXPORT\ORDZPW.CSV
ECHO -------------------------------------------------
ECHO %0 - ET-Order:
ECHO -- Die zu uebertragende Datei finden Sie
ECHO -- auf diesem Computer im Verzeichnis C:\PGEXPORT
ECHO -- unter dem Namen  ORDZPW.CSV  (s.o.)
ECHO -- fuer den elektronischen Versand bereitgestellt
ECHO --                                      ...RETURN
ECHO -------------------------------------------------
PAUSE >NUL:

:OQX6
rem -- try to call link procedure --
IF     EXIST H2XZPW.HTM GOTO OQX60
GOTO OQX68
:OQX60
START        H2XZPW.HTM
GOTO OQX68
:OQX68
rem -- CD \
GOTO OQXEND

:OQXEND
GOTO ENDUP

REM 
REM -- H2XZPW.BAT - FINAL --

 REM 6789.123456789.123456789.123456789.123456789.123456789.123456789.12345
 REM ----------------------------------------------------------------------

:ENDUP
SET PGOEPCPI=

REM -- now return to PGO home drive and resume PGO mainline --
rem -- %2
rem -- CD \
rem -- CD %3
SET  PGOEPCPI=PGOBEG
IF "%PGONETID%"=="W10" SET PGOEPCPI=START /R /MAX PGOFFICE.PIF
IF "%PGONETID%"=="W16" SET PGOEPCPI=START /R /MAX PGOFFICE.PIF
IF "%PGONETID%"=="W95" SET PGOEPCPI=START /R /MAX PGOFFICE.PIF
IF "%PGOEPCEX%"=="END" SET PGOEPCPI=
%PGOEPCPI%
EXIT
