home *** CD-ROM | disk | FTP | other *** search
/ ftp.wwiv.com / ftp.wwiv.com.zip / ftp.wwiv.com / pub / BBS / IDXUTIL6.ZIP / SHELL.DOC < prev    next >
Text File  |  1993-06-16  |  1KB  |  36 lines

  1. SHELL.PPE is a very simple PPE to allow you to shell out to a program
  2. during a display file or PCBTEXT entry. Here is the entire Source Code:
  3.  
  4. INTEGER Dummy
  5. SHELL 0, Dummy, GETTOKEN(), REPLACE(TOKENSTR(),";"," ")
  6. END
  7.  
  8. The first item is assumed to be the COMPLETE program Drive:\Path\Program.Ext
  9. and anything else is passed to the program (except spaces will get trimmed
  10. down, everything will be uppercase and any ';' characters will be changed
  11. to spaces.) Here is an example usage within a CD-ROM conference INTRO file:
  12.  
  13. !C:\PCB\PPE\SHELL.PPE C:\PROG\IDX-TEST.EXE C:\PROG\IDX-RSET.CFG CDSTATUS /Q
  14. %CDSTATUS
  15.  
  16. This will Shell out to IDX-TEST which will read the IDX-RSET.CFG file and
  17. create the CDSTATUS file which then gets displayed upon return to the text
  18. file. You could change the source code to:
  19.  
  20. INTEGER Dummy
  21. SHELL GETTOKEN(), Dummy, GETTOKEN(), REPLACE(TOKENSTR(),";"," ")
  22. END
  23.  
  24. Which would then require you to specify a 0 (or non-Zero to SHELL via
  25. command.com) as the first parameter. This would allow running batch files.
  26.  
  27. !C:\PCB\PPE\SHELL.PPE 0 C:\PROG\IDX-TEST.EXE C:\PROG\IDX-RSET.CFG CDSTATUS /Q
  28. %CDSTATUS
  29.  
  30. or
  31.  
  32. !C:\PCB\PPE\SHELL.PPE 1 RUNME.BAT C:\PROG\IDX-RSET.CFG CDSTATUS /Q
  33. %CDSTATUS
  34.  
  35. >>>>>Gary Meeker
  36.