• 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: NSDocument: how to save document as a simple text file
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSDocument: how to save document as a simple text file


  • Subject: Re: NSDocument: how to save document as a simple text file
  • From: Scott Anguish <email@hidden>
  • Date: Fri, 26 Apr 2002 17:09:51 -0400

not wanting to cloud the issue, but this isn't necessarily true.

the -dataRepresentationOfType: method is one option.. another would be implementing

- (BOOL)writeToFile:(NSString *)fileName ofType:(NSString *)type

which would then logically call writeToFile:atomically:

When dealing with writing file wrappers, this is the appropriate method.

again, it might be me being pedantic.. but it is just as legitimate as the other method.

there is a complete NSDocument article at http://www.stepwise.com/Articles/HTMLEditorX


On Friday, April 26, 2002, at 01:53 PM, mmalc crawford wrote:

Several days ago I asked how to save a document as a simple text file
In an NSDocument based Cocoa app.
Well several readers (thanx) pointed out to use the method writeToFile:path
atomically: to save it as a text file.

Unfortunately it looks lke you were led astray...
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: NSDocument: how to save document as a simple text file (From: mmalc crawford <email@hidden>)

  • Prev by Date: Subclassing NSDictionary...
  • Next by Date: Re: NSInvalidArgumentException : can't send message to abstract object
  • Previous by thread: Re: NSDocument: how to save document as a simple text file
  • Next by thread: Application, Home, ... folders
  • Index(es):
    • Date
    • Thread