On Sep 25, 2010, at 9:12 AM, Brad Stone wrote:

> I have an NSMutableString that I want to set as the NSData source for an 
> NSTextView.  I'm stuck and don't know how to do it.   I'm importing about 
> 4,000 XML files and I have to programmatically create the attributedString 
> for each one, there's no way around it.
> 
> How do I convert an NSMutableString to NSData so it can be the data source 
> for an NSTextView?

NSTextView doesn't use NSData as its "data source"--it uses NSTextStorage. You 
can get its content as a mutable string using -mutableString and manipulate it.

Keary Suska
Esoteritech, Inc.
"Demystifying technology for your home or business"

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to