By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,291 Members | 3,096 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,291 IT Pros & Developers. It's quick & easy.

play video

P: n/a
Again, I am a beginer, and need help.
Can some walk me through the steps to do the following:
click a button, which will play a video file in WMP in fullscreen mode
(launch player, not in a form)
then when the video is done playing, I want the player to close, then the
form that had the button to also close.
I really do not have a clue, so I need very basic instruction.

Thanks to those of you that share what you know so the rest of us can learn.

Jan 6 '07 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Hello,

I think it's possible to do this using the old mplayer2.exe (version 6.4)
which is in the same folder as Windows Media Player (up to version 10).
It accepts parameters, such as /close and /fullscreen.
(http://support.microsoft.com/kb/241422/en-us)

An example in VB 2005:

Public Class Form1

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click

Dim a As New Process
a =
Process.Start(My.Computer.FileSystem.SpecialDirect ories.ProgramFiles + _
"\Windows Media Player\mplayer2.exe", "/play /close /fullscreen
Path-File.wmv")
Me.Close()
End Sub

End Class

The form will close after WMP has turned up. At the moment, I don't know how
I can change that.
I could not test it because I have Vista and WMP 11, so please try it and
tell us whether it works or not. Hope this helps.

"John Piper" wrote:
Again, I am a beginer, and need help.
Can some walk me through the steps to do the following:
click a button, which will play a video file in WMP in fullscreen mode
(launch player, not in a form)
then when the video is done playing, I want the player to close, then the
form that had the button to also close.
I really do not have a clue, so I need very basic instruction.

Thanks to those of you that share what you know so the rest of us can learn.
Jan 6 '07 #2

P: n/a
I have WMP 11, so that did not work. I think I need a way to play the
video, but do not know how (like I said I am clueless). I want it to do as
I said, however, to work on most machines, so maybe another more "global"
way so to say.

Thanks again to everyone
"P. Di Stolfo" <PD*******@discussions.microsoft.comwrote in message
news:15**********************************@microsof t.com...
Hello,

I think it's possible to do this using the old mplayer2.exe (version 6.4)
which is in the same folder as Windows Media Player (up to version 10).
It accepts parameters, such as /close and /fullscreen.
(http://support.microsoft.com/kb/241422/en-us)

An example in VB 2005:

Public Class Form1

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click

Dim a As New Process
a =
Process.Start(My.Computer.FileSystem.SpecialDirect ories.ProgramFiles + _
"\Windows Media Player\mplayer2.exe", "/play /close /fullscreen
Path-File.wmv")
Me.Close()
End Sub

End Class

The form will close after WMP has turned up. At the moment, I don't know
how
I can change that.
I could not test it because I have Vista and WMP 11, so please try it and
tell us whether it works or not. Hope this helps.

"John Piper" wrote:
>Again, I am a beginer, and need help.
Can some walk me through the steps to do the following:
click a button, which will play a video file in WMP in fullscreen mode
(launch player, not in a form)
then when the video is done playing, I want the player to close, then the
form that had the button to also close.
I really do not have a clue, so I need very basic instruction.

Thanks to those of you that share what you know so the rest of us can
learn.

Jan 7 '07 #3

P: n/a
Could you not create a second blank form minus title bar etc and drop the
windows media player activex control on the form. The controls of the
player are then exposed for full screen, close, media file (url) etc.

"john piper" <jo**@piper.comwrote in message
news:sW***********@tornado.tampabay.rr.com...
>I have WMP 11, so that did not work. I think I need a way to play the
video, but do not know how (like I said I am clueless). I want it to do as
I said, however, to work on most machines, so maybe another more "global"
way so to say.

Thanks again to everyone
"P. Di Stolfo" <PD*******@discussions.microsoft.comwrote in message
news:15**********************************@microsof t.com...
>Hello,

I think it's possible to do this using the old mplayer2.exe (version 6.4)
which is in the same folder as Windows Media Player (up to version 10).
It accepts parameters, such as /close and /fullscreen.
(http://support.microsoft.com/kb/241422/en-us)

An example in VB 2005:

Public Class Form1

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click

Dim a As New Process
a =
Process.Start(My.Computer.FileSystem.SpecialDirec tories.ProgramFiles + _
"\Windows Media Player\mplayer2.exe", "/play /close /fullscreen
Path-File.wmv")
Me.Close()
End Sub

End Class

The form will close after WMP has turned up. At the moment, I don't know
how
I can change that.
I could not test it because I have Vista and WMP 11, so please try it and
tell us whether it works or not. Hope this helps.

"John Piper" wrote:
>>Again, I am a beginer, and need help.
Can some walk me through the steps to do the following:
click a button, which will play a video file in WMP in fullscreen mode
(launch player, not in a form)
then when the video is done playing, I want the player to close, then
the
form that had the button to also close.
I really do not have a clue, so I need very basic instruction.

Thanks to those of you that share what you know so the rest of us can
learn.

Jan 12 '07 #4

This discussion thread is closed

Replies have been disabled for this discussion.