Jafar Al-Gharaibeh ha escrit el 17/01/08 19:17:
> Hi,
>
> I have tested the following program under Windows XP Home
>
> procedure main()
>
> fname := "a\\data.txt"
> fin := open(fname) | stop("can't open ", fname)
> s:=reads(fin, 20)
> write(s)
> read()
>
> end
>
> I tested the program with "a\\data.txt" , "a/data.txt" and even
> "a//data.txt"
>
> all of them worked just fine and I got the expected result.
>
> I assume that "\\" and "/" are interchangeable and work correctly
> under Windows.
>
> Thanks,
> Jafar.
>
Hi Jafar,
Thanks so much. You are a gentleman and a scholar. This is what I
thought. The bad news is now I have no clue as to why some Windows users
can't open the data file. My code looks like this:
# Setup i/o
datadir := "Data/"
outdir := "Output/"
resp := "y"
while resp == "y" do {
writes("Specify page to proof: ")
flnm := read()
infile := open(datadir || flnm || ".txt") | stop("can't open data
file: ", chdir(), "/", datadir, flnm, ".txt")
outfile := open((outdir || flnm || ".out"), "w") | stop("can't open
output file: ", chdir(), "/", outdir, flnm, ".out")
Could this be a Vista issue?
Anyway thanks again for your help.
Cheers,
Jonathan
--
Jonathan Kaye
Sip Phone: [EMAIL PROTECTED]
Registered Linux user #445917 at http://counter.li.org/
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Unicon-group mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/unicon-group