• 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: checking if directory is writable
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: checking if directory is writable


  • Subject: Re: checking if directory is writable
  • From: "Rick C." <email@hidden>
  • Date: Wed, 11 Jan 2012 09:52:16 +0800

Great thanks Mike!


On Jan 10, 2012, at 8:03 PM, Mike Abdullah wrote:

> In order of preference, the best technique last:
>
> 1. -attributesOfItemAtPath:error:	—	can only give you some info info on if the file is writable
> 2. -isWritableAtPath:				—	takes more into account, but can't be sure. Gives you no details on *why* isn't writable
> 3. Actually try to write the directory
>
> Always, always use #3 if you can; it's the only way to be sure.
>
> On 10 Jan 2012, at 08:49, Rick C. wrote:
>
>> Hi,
>>
>> Just looking for confirmation, I can use NSFileManager isWritableAtPath: if I want to check if a directory can be written to correct?  Or do I have to use attributesOfItemAtPath:error:?  I don't need to change permissions just to see if it's writable.  Thanks!
>>
>> rc_______________________________________________
>>
>> 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
>

_______________________________________________

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

References: 
 >checking if directory is writable (From: "Rick C." <email@hidden>)
 >Re: checking if directory is writable (From: Mike Abdullah <email@hidden>)

  • Prev by Date: Re: Respecting tabs across applications
  • Next by Date: Re: Respecting tabs across applications
  • Previous by thread: Re: checking if directory is writable
  • Next by thread: Re: checking if directory is writable
  • Index(es):
    • Date
    • Thread