home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Carsten's PPE Collection
/
Carstens_PPE_Collection_2007.zip
/
S
/
SENDFIL1.ZIP
/
SENDFILE.PPS
< prev
next >
Wrap
Text File
|
1995-08-01
|
4KB
|
155 lines
;PPE to offer the user to flag files for downloading from a text file.
;Can also be run as a PPE to offer specific file choices.
;
;Needs <ppename>.cfg to hold the names of files to prompt
;The CFG file (SENDFILE.CFG) contains a header entry of 5 lines and
;entries for each file consisting of 5 lines each:
;
;
;DISPLAY1=line to display as a header - include even if blank
;DISPLAY2=line to display as a header - include even if blank
;DISPLAY3=line to display as a header - include even if blank
;DISPLAY4=line to display as a header - include even if blank
;DISPLAY5=line to display as a header - include even if blank
;FILE1_line1=FILENAME
;FILE1_line2=FULL PATH TO FILE (E:\PCB\UPLOAD\) WITH TRAILING BACKSLASH
;FILE1_line3=DESCRIPTION LINE 1 (even if blank)
;FILE1_line4=DESCRIPTION LINE 2 (even if blank)
;FILE1_line5=DESCRIPTION LINE 3 )even if blank)
;FILE2_line1=FILENAME
;FILE2_line2=FULL PATH TO FILE (E:\PCB\UPLOAD\) WITH TRAILING BACKSLASH
;FILE2_line3=DESCRIPTION LINE 1 (even if blank)
;FILE2_line4=DESCRIPTION LINE 2 (even if blank)
;FILE2_line5=DESCRIPTION LINE 3 )even if blank)
;Repeat for each file
;
;
;For example:
;Contents of SENDFILE.CFG to prompt for three files:
;@X1C------------------------------------------------------------------------------
;@X1F@BOARDNAME:79C@
;@X1F File Helper
;@X1C------------------------------------------------------------------------------
;
;BGI20.ZIP
;E:\PCB\DL03\
;"The Beginner's Guide to the Internet" is a full-color, computer-based
;tutorial about the Internet. It covers E-mail, ftp, telnet, gopher,
;Archie, Veronica, WAIS, World Wide Web, newsgroups, mailing lists, etc.
;INTEMAIL.ZIP
;E:\PCB\DL03\
;How to do almost anything on the Internet using only E-Mail! This
;special report will show you how to retrieve files from FTP sites,
;Gopher, Archie, Veronica, WAIS, World-Wide Web and more.
;ISFQ1194.ZIP
;E:\PCB\DL03\
;alt.internet.services frequently asked questions as of 11-21-94 -
;downloaded from rtfm.mit.edu in /pub/usenet/alt.internet.services
;Much useful information.
;
;NO COMMENT LINES ARE ALLOWED IN THE CFG FILE!
;
;
;To use in multiple instances, just use a different name for the PPE and
;the CFG file. They must be the same, but you can use any name you want.
;
;To prompt a user to flag files from a bulletin, new file or amy text file
;just insert a line with a "!" and the full path to SENDFILE.PPE (or whatever
;you have named it) where you want the user prompted:
;
;!e:\pcb\ppe\sendfile.ppe
;
;No headers or PPE description/menu lines are shown. The user sees:
;
;Flag <filename> for downloading (Y/N):
;
;If the answer is Y, the user sees:
;
;*****<filename> flagged for later downloading.
;
;Questions or comments should be sent to:
;elizabeth.copper@daycal.cts.com
;or you can call Daily Calendar BBS
;in Coronado, CA at 619-435-2687.
INTEGER i ;LINE NUMBER IN CFG FILE
STRING fname, fpath, desc1, desc2, desc3 ;LINE CONTENTS IN CFG FILE
STRING h1, h2, h3, h4, h5 ;HEADER LINES
STRING answer
FOPEN 1, PPEPATH()+PPENAME()+".CFG",O_RD,S_DW
IF (FERR(1)) THEN
LET fname = "Error opening file "+PPEPATH()+PPENAME()+".CFG"
PRINTLN fname
END
ENDIF
FDEFIN 1
FDGET h1
INC i
FDGET h2
INC i
FDGET h3
INC i
FDGET h4
INC i
FDGET h5
INC i
IF (!LEN(TRIM(h1," "))=0) THEN
PRINTLN h1
ENDIF
IF (!LEN(TRIM(h2," "))=0) THEN
PRINTLN h2
ENDIF
IF (!LEN(TRIM(h3," "))=0) THEN
PRINTLN h3
ENDIF
IF (!LEN(TRIM(h4," "))=0) THEN
PRINTLN h4
ENDIF
IF (!LEN(TRIM(h5," "))=0) THEN
PRINTLN h5
ENDIF
WHILE (!FERR(1)) DO
FDGET fname
INC i
FDGET fpath
INC i
FDGET desc1
INC i
FDGET desc2
INC i
FDGET desc3
IF (!LEN(TRIM(fname," "))=0) THEN
LET answer = YESCHAR()
PRINTLN "@X1C"+fname
PRINTLN "@X1C"+desc1
PRINTLN "@X1C"+desc2
PRINTLN "@X1C"+desc3
NEWLINE
INPUTSTR "Flag "+fname+" for downloading (Y/N): ",answer,@X1F,1,"YyNn",YESNO+AUTO
NEWLINE
IF (LEN(TRIM(answer," "))=0) THEN
END
ENDIF
IF (UPPER(answer)="Y") THEN
FLAG fpath+fname
PRINTLN "@X1F*****"+fname+" flagged for later downloading."
NEWLINE
ENDIF
ENDIF
INC i
ENDWHILE
FCLOSE 1
END