• 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: NSFileManager's odd behavior
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSFileManager's odd behavior


  • Subject: Re: NSFileManager's odd behavior
  • From: Shane Stanley <email@hidden>
  • Date: Wed, 22 Jul 2015 21:23:12 +1000

On 22 Jul 2015, at 9:09 pm, Takaaki Naganoya <email@hidden> wrote:
>
> This script generates 1000 folders on Desktop/test by using Cocoa NSFileManager.
> But this stops after few folder generated. Why?

> <snip>

> 	set aRes to (fileManager's createDirectoryAtPath:dirPath withIntermediateDirectories:true attributes:false |error|:(reference))

The problem is the attributes parameter. The documentation says it should be either a dictionary of attributes, or nil. Change that false to (missing value).

> 	-->	error number -10000  -[__NSCFBoolean objectForKey:]: unrecognized selector sent to instance 0x7fff740798b8

I suspect that __NSCFBoolean is your false argument; objectForKey: is a dictionary method, hence the exception.

--
Shane Stanley <email@hidden>
<www.macosxautomation.com/applescript/apps/>


 _______________________________________________
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


  • Follow-Ups:
    • Re: NSFileManager's odd behavior
      • From: Takaaki Naganoya <email@hidden>
References: 
 >NSFileManager's odd behavior (From: Takaaki Naganoya <email@hidden>)

  • Prev by Date: NSFileManager's odd behavior
  • Next by Date: Re: NSFileManager's odd behavior
  • Previous by thread: NSFileManager's odd behavior
  • Next by thread: Re: NSFileManager's odd behavior
  • Index(es):
    • Date
    • Thread