• 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
Is a file open in another application?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Is a file open in another application?


  • Subject: Is a file open in another application?
  • From: Brad Stone <email@hidden>
  • Date: Sat, 19 Mar 2011 09:34:51 -0400

Is there a way for me to tell if a particular file is open in another application?

I have a feature I'd like to provide to my users that involves encrypting files that belong to other apps (i.e. my application can encrypt/decrypt a Word or Excel file).  I want to prevent the user from encrypting or decrypting the file if it's open (i.e. the file is open in Word).  I would like to display a dialog box that says something like "myWord Doc.docx is open.  Please close it and continue."  I've found the ability to find running applications and I've found commentary that says what I'm asking for is not possible.  I couldn't find anything in NSWorkspace or NSFileManager to help unless there's a file attribute I don't know about that can tell me.  Any ideas?

Thanks in advance_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Is a file open in another application?
      • From: Dave Keck <email@hidden>
    • Re: Is a file open in another application?
      • From: "email@hidden" <email@hidden>
    • Re: Is a file open in another application?
      • From: Conrad Shultz <email@hidden>
  • Prev by Date: Re: NSMatrix bindings
  • Next by Date: Re: Is a file open in another application?
  • Previous by thread: Re: Icon not bouncing in Dock when App started
  • Next by thread: Re: Is a file open in another application?
  • Index(es):
    • Date
    • Thread