Playing Video with windows media player in C#
-
I was wondering if anyone knows how to play a video with windows media player in C#. i got the player loaded onto my form but i cann't figure out how to tell it what video to play. any ideals:confused:? thanks kevin
SetURL to your video file name. eric feng www.infospec.com
-
I was wondering if anyone knows how to play a video with windows media player in C#. i got the player loaded onto my form but i cann't figure out how to tell it what video to play. any ideals:confused:? thanks kevin
Do a bit search on www.microsoft.com, you will find a good tutorial about how to use it in VB.Net, you can use the same code in c#.
Don't forget, that's
Persian Gulf
not Arabian gulf!
-
SetURL to your video file name. eric feng www.infospec.com
-
Do a bit search on www.microsoft.com, you will find a good tutorial about how to use it in VB.Net, you can use the same code in c#.
Don't forget, that's
Persian Gulf
not Arabian gulf!
-
thanks that helped so much. what do you think i did before i posted this message? i searched for a good hour with out any luck on finding anything that made sense to me. :(
I did a bit search and this is what I found: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnwmt/html/vb_player_article.asp[^] I hope this helps:rose:
Don't forget, that's
Persian Gulf
not Arabian gulf!
-
Player.AutoStart = true; Player.URL = "c:\movie.avi"; eric feng www.infospec.com
-
thanks that helped so much. what do you think i did before i posted this message? i searched for a good hour with out any luck on finding anything that made sense to me. :(
You need to check what version you are using becauce the commands changed completely between the two? If you have installed media player 9 it will over write the exiting componet the came with VS. Here is a sample of the older version which I think is the one that you have got! private AxMediaPlayer.AxMediaPlayer VideoScreen; VideoScreen = new AxMediaPlayer.AxMediaPlayer(); string FullPathAndFileName = @"C:\MyVideo.avi"; VideoScreen.FileName = FullPathAndFileName; VideoScreen.Play(); Hope this helped Leon v Wyk