[REBOL] Another newbie stumper
From: kpeters::vu-ware::com at: 3-Mar-2005 12:07
Hi all ~
another one has me baffled:
the print statement in script below shows the proper expected filenames
the write immediately below fails showing a different dest directory:
>> do %/c/city/rename.r
Script: "Untitled" (none)
c/city/pdfs/short/1.pdf
** Access Error: Cannot open /c/city/c/city/pdfs/short/1.pdf
** Near: write/binary new pdf
REBOL[]
files: read %/c/city/pdfs/
i: 1
foreach file files[
pdf: read/binary append copy %/c/city/pdfs/ file
new: replace copy %c/city/pdfs/short/@.pdf "@" i
i: i + 1
print new
write/binary new pdf
]
What do I need to learn here?
As always, thanks for any pointers,
Kai