problems with lowercase and uppercase characters in filenames

Jan Schenkel janschenkel at
Wed Jul 9 07:20:31 EDT 2008

--- runrev260805 at wrote:
> Hi,
> i ran into a problem with case sensity writing 2
> files ("c:/Test.txt" and "c:/test.txt") under
> Windows wit Rev Studio 2.9.
> Only the first file is created. The content for the
> second file is written to the first file.
> Is Rev not aware of lower/uppercase filenams? 
> Tried the following script, which should do it, but
> it doesn´t
> ON mouseUp pMouseBtnNo
>     open file "c:/Test.txt" FOR write
>     write "text for the uppercase file" to file
> "c:/Test.txt"
>     close file "c:/Test.txt"
>     open file "c:/test.txt" FOR write
> -- this command reopens the file "c:/TEST.txt"
> instead of creating a new one with the lowercase
> filename
>     write "text for the lowercase file" to file
> "c:/test.txt"
>     close file "c:/test.txt"
> End mouseUp
> So where is my mistake?
> Regards,
> Matthias

Hi Matthias,

Unlike Unix-based operating systems (MacOSX, Linux),
Windows doesn't differentiate between uppercase and
lowercase letters in file names.
You can't even create two files with the same name in
mixed cases, using the Windows Explorer.
So "Test.txt" will be the same file as "test.txt" and
Revolution will overwrite the file with the contents
of your second write cycle.

Hope this clarified it,

Jan Schenkel.

Quartam Reports & PDF Library for Revolution

"As we grow older, we grow both wiser and more foolish at the same time."  (La Rochefoucauld)


More information about the Use-livecode mailing list