home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Club Amiga de Montreal - CAM
/
CAM_CD_1.iso
/
files
/
553.lha
/
ClockDJ_v5.02
/
ClockRexxExamples
/
PointCopy.rexx
< prev
next >
Wrap
OS/2 REXX Batch file
|
1991-09-09
|
998b
|
38 lines
/* Multiple file copy */
options results
address clockdj
setcedhide ""
setcedshow ""
setcedtitle "Select files to copy"
setceddir "VD0:"
setcedfile ""
cedextendedrequester
files = result;if files = "" then exit
setceddir "RAM:"
setcedtitle "Select destination directory"
cedrequesterdir
dir = result;if dir = "" then exit
win = "con:s*/0/50/640/350//cd/02\r\c"
if ~open('console',win) then exit /* Window for all activity */
call writeln 'console','9b'x'1;32;40mCopy:'||'9b'x'0;31;40m'
call writech 'console',files
call writeln 'console','9b'x'1;32;40mTo: '||'9b'x'0;31;40m'||dir
POPREQUESTER 'Do you really want to copy these?'
if result = no then exit
address command
if index(files,'0a'x) = 0 then do
"runwsh >nil: copy >nil:" '"'files'"' "to" dir "clone"
exit
end
pos1 = 1
do forever
pos2 = index(files,'0a'x,pos1+1)
if pos2 = 0 then do
say 'All done.';exit
end
else nop
"runwsh >nil: copy >nil:" '"'substr(files,pos1,(pos2-pos1))'"' "to" dir "clone"
pos1 = pos2+1
end