• 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: Can't copy files...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Can't copy files...


  • Subject: Re: Can't copy files...
  • From: Ondra Cada <email@hidden>
  • Date: Wed, 12 Dec 2001 21:46:28 +0100

Riccardo,

>>>>>> Riccardo Santato (RS) wrote at Wed, 12 Dec 2001 21:09:18 +0100:
RS> I'm toying 'round with NSFileManager class and I'm stuck into copying
RS> files. I'm trying to copy some files I chose from an NSBrowser (let's
RS> call it "source_browser") to another one (called "dest_browser").
RS> Here's the incriminated code:
RS>
RS> [fm copyPath:[source_browser path] toPath:[dest_browser path]
RS> handler:nil];
RS>
RS> "fm" is a filemanager that it's allocated via the selector
RS> "defaultManager" when the NIB awakes. The program doesn't give me any
RS> error, NSFileManager doesn't need delegates, and the above function
RS> returns me a TRUE boolean (checked with an if/else conditional block).
RS> Can you give me a little hand, please ? :-))

It should work. Have you tried to check whether you aren't copying somwthing
different than you meant to? Like

NSString *from=[source_browser path],*to=[dest_browser path];
BOOL ret;
NSLog(@"Copying (%@) to (%@) using %@",from,to,fm);
ret=[fm copyPath:from toPath:to handler:nil]
NSLog(@"Result %d",ret);
---
Ondra Cada
OCSoftware: email@hidden http://www.ocs.cz
2K Development: email@hidden http://www.2kdevelopment.cz
private email@hidden http://www.ocs.cz/oc


  • Follow-Ups:
    • Re: Can't copy files...
      • From: Riccardo Santato <email@hidden>
References: 
 >Can't copy files... (From: Riccardo Santato <email@hidden>)

  • Prev by Date: Re: I have NOT signed that petition!
  • Next by Date: Re: The issue of metadata
  • Previous by thread: Can't copy files...
  • Next by thread: Re: Can't copy files...
  • Index(es):
    • Date
    • Thread