loop for Cursor1.moveToPosition() in android
<p>I want to get data in the first column of all row from my database and convert to String[]
... </p>

<pre><code>List&lt;String&gt; item1 = new ArrayList&lt;String&gt;();
// c is a cursor which pointed from a database
for(int i=0;i&lt;=nombre_row;i++)
    {
        c.moveToPosition(i);
        item1.add(c.getString(0));
    }
String[] strarray = new String[item1.size()];
item1.toArray(strarray );
</code></pre>

<p>I've tried to comment step by step, and found that the problem is in the Loop for....
Please help... thanks in advance for all answer.</p>
