There is no connection on Visible and Locked files on Windows systems. If setting the file to invisible locks the file then it is a bug.

Björn

Arnaud Nicolet wrote:
If it's a bug, I think it's standard Win32 behaviour. (sorry, annoyed for how Win32 "works").

I certainly think Win32 locks invisible files for whatever reason, simply because this OS always feels free to modify behaviours based on facts that have nothing to do with. In other words, I'm not surprised that setting a file to invisible locks it under Win32.

But, I could be wrong for that case, indeed. I'll check that.

Le 3 janv. 07 à 12:32 Soir, Trausti Thor Johannsson a écrit:

I found out the bug, perhaps not a bug, but I would like to call it like that.

f.visible = false

Makes the file write protected under windows. By removing that line, everything works.
I consider this a bug.

Trausti
On Jan 3, 2007, at 4:10 AM, William Squires wrote:

Try creating an intermediate TextOutputStream object:

Dim o As TextOutputStream
...
o = f.CreateTextFile()
o.Write(strPreferences)

and see if 'o' is nil. Also, try making the file invisible AFTER you create it and see what happens.

On Jan 2, 2007, at 5:38 PM, Trausti Thor Johannsson wrote:

This works fine on Macintosh, but crashes as a nilobject on Windows. I have no explanation, here is the code

    #if TargetMachO then
      f = PreferencesFolder.Child("studlar")
    #elseif TargetWin32 then
      f = PreferencesFolder.Child("studlar")
    #endif
    f.Visible = false
    if f.Exists then
      f.CreateTextFile().Write(strPreferences)  <---- crashes here
     end if


No variable is nil, that is so weird.


Trausti


This bug is in 2006r4 and 2007r1.


Trausti

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>




_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Reply via email to