<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7650.5">
<TITLE>Re: [Pythonmac-SIG] ascii &lt;-&gt; unicode &lt;-&gt; cocoa NSString</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/plain format -->

<P><FONT SIZE=2>On 2/20/06 1:05 PM, &quot;Keith Ray&quot; &lt;keith.ray@gmail.com&gt; wrote:<BR>
<BR>
&gt; Help ?<BR>
<BR>
You encode from Unicode, and decode to Unicode:<BR>
<BR>
&gt;&gt;&gt; 'hi there'.decode('ascii')<BR>
u'hi there'<BR>
&gt;&gt;&gt; u'hi there'.encode('ascii')<BR>
'hi there'<BR>
<BR>
Dave<BR>
<BR>
</FONT>
</P>

</BODY>
</HTML>