BurakSZ Posted June 5, 2010 Posted June 5, 2010 Hey Guys, I want to put a Windows Media Player into a GUI. My Script: #include <GUIConstants.au3> $gui = GUICreate("",250,255) $oMP = ObjCreate("WMPlayer.OCX") $mediaplayer = GUICtrlCreateObj($oMP, 5, 5, 300, 300) GUISetState(@SW_SHOW) With $oMP .fullScreen = True .windowlessVideo = False .enableContextMenu = True .enabled = True .uiMode = "full" .settings.autostart = True .settings.mute = False .settings.volume = 100 .settings.Balance = 0 .URL = "http://blackbeats.fm/listen.asx" EndWith While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd You see that I have a video. How do I delete that video, so I just have Play, Stop, ... ? I don't know the command for it I searched for it and it told me to set the heigth to 40, but this just shows me a black window there... Greets BurakSZWindows Media Player.au3
ajit Posted June 5, 2010 Posted June 5, 2010 Try this #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> $hGUI = GUICreate("Media Player", 300, 100, 215, 10, Default, Default) GUISwitch($hGUI) $h_cGUI = GUICreate("Embed Player", 242, 41, 20, 20, $WS_CHILD, "", $hGUI ) $oMP = ObjCreate("WMPlayer.OCX") $mediaplayer = GUICtrlCreateObj($oMP, 0, -200 , 600, 385) With $oMP .fullScreen = True .windowlessVideo = False .enableContextMenu = True .enabled = True .uiMode = "full" .settings.autostart = True .settings.mute = False .settings.volume = 100 .settings.Balance = 0 .URL = "http://blackbeats.fm/listen.asx" EndWith GUISetState(@SW_SHOW, $hGUI) GUISetState(@SW_SHOW, $h_cGUI) While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now