Sunday 8 May 2011

Windows Media Player Control in C#

Window Media Player
You will not find the window media player control on toolbox list, so you have to add this control on rightclick on tool box and select option choose item as shown in below picture.
                                     
After this you will get another window for choosing toolbox item go to COM component panel and check window media player item and then click ok button. This control will add on your Visual Studio Framework toolbox list.

                                    

Now you can drag and drop window media player control from toolbox list.
                                    
Code for playing a song on window media player.   

private void Form1_Load(object sender, EventArgs e)
        {
            axWindowsMediaPlayer1.URL = @"D:\Documents and Settings\R4R\My Documents
\Downloads\aakrosh02(www.songs.pk).mp3";
        }
                                  

3 comments:

  1. sorry, beacuse your post, this is orrible, because this example for kid-school.

    is related want post, whit more information not stupids..

    ReplyDelete