Fileopen bug.

Archives Forums/Blitz3D Bug Reports/Fileopen bug.

Fernhout(Posted 2009) [#1]
I found out that opening of a file is not always working. When i want to open a file, if the file is in the folder where the program is, openening of the file is working.
But when i try to open a file is a sub folder i got a 0(zero) back.

e.g.
fileio1 = OpenFile ("include\about.bb")
fileio2 = OpenFile ("TODO.bb")

Both file exist
-Fileio1 return a 0
-Fileio2 return a handler number

Is this a compiler bug or is this delibertly done
OR is there something i do realy wrong.

N.B. Sorry for my bad englisch

Bart Fernhout.


skidracer(Posted 2009) [#2]
If you are running Vista, you may want to test with ReadFile, if this succeeds your program may not have permissions to write to files in that directory (OpenFile should only used when you need to read AND write).