• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag
 

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Open for access with write permission
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Open for access with write permission


  • Subject: Re: Open for access with write permission
  • From: email@hidden
  • Date: Mon, 24 Mar 2008 23:34:05 +0100

At 1:35 PM -0700 3/24/08, Houston, Brad wrote:
I've also encountered this problem (OS 10.4.10) when crashing before closing
a file opened for write access on the desktop. Afterwards, I can't open it,
because it's already open. OK, fine. But I can't close it, from the same
script or one written just to close it, because it then says it's not open
to be closed.
The "close" command is wrapped in a try statement prior to the "open"
command, so if it is already open it should close it before re-opening it,
or, if not open, won't crash the program trying to close something that
doesn't exist.
Eventually I get annoyed enough and restart the machine, which is the only
reliable way I've found around this loop of denial.

In fact the situation is worse than that: even if you trash the file you still can't run a "open for access with write permission", as if the file was still stuck in the folder.


The pseudo-locking system provided by "with write permission" has some limits that should be known:
1/ only the process which opened the file can close it, whence an obvious problem if that process crashes,
2/ attempting to open with write permission a file which is already has various results depending on what process does: same process -> error number -49 (file is already open), other process on the same machine -> error number -54 (file permission error), other process on a different machine -> no error.


Emmanuel
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden
References: 
 >Re: Open for access with write permission (From: "Houston, Brad" <email@hidden>)

  • Prev by Date: Set Permissions on Files in OS X Shared Folder
  • Next by Date: Re: Image Events problem.
  • Previous by thread: Re: Open for access with write permission
  • Next by thread: Re: Open for access with write permission
  • Index(es):
    • Date
    • Thread