Android mediaplayer play a Songs as orderly
<p>I am new to Android. In my app MediaPlayer plays groups of songs in order. The songs are stored in one arraylist and the song names are stored in another arraylist.. </p>

<pre><code>for(i=0;i&lt; songarray.sizeof();i++)
{
  mp=MediaPlayer.create(this,(Integer) songarray.get(i));

  sname.setText(songname.get(i));
  mp.start
}
</code></pre>

<p>The problem is that the songs play only one then print one song name.</p>
