&comment ******************************************************************* &comment *** UPLOAD script: uploads an item to the current Desk area *** &comment *** from the PC. Initially supports only text files and WRQ's *** &comment *** Reflection. Syntax is simply "UPLOAD" - it uses a dialog *** &comment *** box on the PC to select the file, and HPDesk prompts them *** &comment *** for the subject when the temporary file is copied in. *** &comment *** *** &comment *** Author: Jeff Kell jeff_kell/admin@hpdesk.utc.edu *** &comment *** Administrative Computing Services, 117 Hunter Hall *** &comment *** University of Tennessee at Chattanooga *** &comment *** Chattanooga, TN 37403 (615)-744-4551 *** &comment *** *** &comment *** 05/06/93: Initial release. *** &comment ******************************************************************* &comment See if they're going to send text or binary &forward 3 > &save kind &forward check $ask &print You must specify "T" for Text files or "B" for Binary files. Note that &print Text files must be plain text such as Windows Notepad (*.TXT); Binary &print files include most word processors (Microsoft Word, WordPerfect, Write), &print program files, spreadsheets, and so forth. &save kind $check &save kind > &forward 3 >> 0>> &print ** Please answer T or B to continue, or Q to quit ** &back ask &exit > "Q"> &forward 2 )>> :purge zz :setvar deskfence hpmsgfence :setvar hpmsgfence 2 :continue :reset zz :setvar hpmsgfence deskfence :deletevar deskfence &save refgo &oCSEND {} TO ZZ &forward 3 > "B"> &save refgo ASCII &forward 3 :file zz;code=1269 &save refgo BINARY &save result > "F"> &forward oops > "F"> &forward oops > &forward oops > "RUN">> &save progname >> &save x ";"> &forward 3 0> &save x 1> &save progname 1 > &forward 3 "PCLINK.PUB.SYS"> &forward 2 "PCLINK2.PUB.SYS"> &forward oops :xeq &save result &forward oops > "F"> &print Uploaded to holding area, copying to current area. &forward 4 > "B"> copy from (zz) +Yes &forward 2 copy from (zz) :purge zz &exit $oops &print *** Upload FAILED *** &forward 2 )>> :purge zz &exit