Haha! UI hangs and CPU spikes to the top; battery starts draining fast. <div><br></div><div>&quot;That tingling means it&#39;s working!&quot; </div><div><br></div><div>Only takes a couple of minutes, really. I suppose this is a question I&#39;d have to ask eventually; is there a simple way to spin something like this off as a separate (green) thread, such that Morphic still responds while the job is running?<br>
<br><div class="gmail_quote">On Wed, Aug 4, 2010 at 11:42 PM, Andreas Raab <span dir="ltr">&lt;<a href="mailto:andreas.raab@gmx.de">andreas.raab@gmx.de</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="im">On 8/4/2010 11:25 PM, Casey Ransberger wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
rows := CSVParser parse: (FileStream readOnlyFileNamed:<br>
&#39;/Users/casey/Desktop/SCDB_2010_01_justiceCentered_Vote.csv&#39;)<br>
</blockquote>
<br></div>
Try changing this to:<br>
<br>
file := FileStream readOnlyFileNamed: &#39;myfile.csv&#39;.<br>
file converter: Latin1TextConverter new.<br>
rows := CSVParser parse: file.<br>
<br>
Cheers,<br><font color="#888888">
  - Andreas</font><div><div></div><div class="h5"><br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Got...<br>
<br>
&quot;Error: invalid utf8 input detected&quot;<br>
<br>
Relevant region of code might be...<br>
<br>
MultiByteFileStream&gt;&gt;next<br>
<br>
| char secondChar state |<br>
char := converter nextFromStream: self.<br>
<br>
<br>
converter is a UTF8TextConverter. Wondering if maybe I need a different<br>
text converter? Given that this is a CSV file, I&#39;m thinking the system<br>
might be expecting UTF-8 where it&#39;s actually getting ASCII. The CSV<br>
package hasn&#39;t had any attention in a while, so that makes some sense<br>
(IIRC there was a shift to UTF-8 not very long ago, no?)<br>
<br>
If anyone is wondering, I&#39;m playing with an idea around dynamic<br>
data-centric web interfaces:) and need some raw data to represent, hence<br>
the CSV file.<br>
<br>
Any ideas?<br>
--<br>
Casey Ransberger<br>
<br>
<br>
<br>
<br>
</blockquote>
<br>
<br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Casey Ransberger<br>
</div>