Re: A question about encoding
Re: A question about encoding
- Subject: Re: A question about encoding
- From: Hiro Fujimoto <email@hidden>
- Date: Fri, 19 Mar 2004 06:08:45 +0900
Hi. zhengjl,
You can encode the contents of file using -
initWithBytes:length:encoding: method of NSString .
--
On 2004/03/18, at 18:50, zhengjl wrote:
Hi! cocoa-dev:
I met a question about display messages on NSTextView which saved
in a text file.
I use fuction freopen() to make cupstestppd output to a text file.
but when i try to get the contents of the file and display on
NSTextView (as below):
[resultField setString:[NSString stringWithContentsOfFile:
filePath]];
I found that it can not get string if the file has encoding
characters. (if file without encoding characters, the sentence works
well)
Program entironment:
Mac OS X 10.3 (Chinese)
XCode and Interface Builder
Cocoa and cups source code
Best Regard !
------------------------------------------------------------------------
---------
hiro FUJIMOTO - developer in Japan.
_______________________________________________
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.