Bug #976
closedIf Exist cmd not working correctly always saying true whether exists or not
0%
Description
From both examples below..problem now using the If Exists cmd
B) The bug of first time no exist (false) and secondtime it does exist (true).
A) The bug always (true) in the latest version whether exists or not.
It should work either way correctly in reality.
..
eg: In the original web live version and previous to that all versions if using just the below a) ver it should work like this. It does not need to open a file first to test, because the if exist does this for you in one go.
..
a) //eg: What Brians, Paul & I have always used, (again which again all worked previously ok).
..
If Exist ("mystupiderfile.txt")
Print "yes" //do this true exists
Else
Print "no" //no not exist.
End If
..
b) //eg:Laurant's example
..
Filename$="toto"
Open Out 1, Filename$
If Exist (Filename$) = False Then Print "do not exist" // test if the file already exist
Print "exist"
Close 1
End
..
//His notes: If you use a file name for first time will say not exist, second time will say it exist