How can I use Intent on Java, Android?
<p>I have written the following code for playing video:</p>

<pre><code>private void loadPlayer() {
        Intent youtube=new Intent(Intent.ACTION_VIEW, Uri.parse("http://www.youtube.com/watch?v=CES7xNy70hU")); 
        startActivityForResult(youtube, 100);
}
</code></pre>

<p>My problem is that when the player finishes showing the video it won't close itself and the user needs to press the back button. I need the player to close itself automatically after the video has finished playing. How can I accomplish this?</p>

<p>The target platform is Android - 2.2. </p>
