 <p>Change your code as:</p> <pre><code>String strcategory = getIntent().getExtras().getString("categoriaId"); </code></pre> <p>because you are passing <code>String</code> from onListItemClick to sondaggioActivity Activity and trying to receive as <code>Int</code></p> <p><strong>NOTE :</strong> </p> <p>Second and important point is <code>id</code> is <code>long</code> and you are trying to parsing it to <code>Int</code> which is also not valid . see this post: <a href="http://stackoverflow.com/questions/4355303/how-can-i-convert-a-long-to-int-in-java">How can I convert a long to int in Java?</a></p> <p>Solution is just send id as long from <code>onListItemClick</code> as</p> <pre><code> myIntent.putExtra("categoriaId",id); </code></pre> <p>and receive it as in <code>sondaggioActivity</code> Activity :</p> <pre><code>long category = getIntent().getExtras().getLong("categoriaId"); </code></pre>