Gif Posted May 2, 2007 Share Posted May 2, 2007 While 1 $msg = GuiGetMsg() Select Case $msg = $GUI_EVENT_CLOSE $confirmexitx = MsgBox(4, "Confirm", "Are you sure you want to exit ?") if $confirmexitx = 6 then Exit if $confirmexitx = 7 then WinClose("Confirm") if @error = 1 then Exit Case $msg = $btn_play $lbl_showsongfile = GUICtrlCreateLabel(GUICtrlRead($input_open), 160, 110, 270, 40) $sound = _SoundOpen(GUICtrlRead($input_open)) If @error = 2 Then MsgBox(0, "Error", "The file does not exist") ElseIf @error = 3 Then MsgBox(0, "Error", "The alias was invalid") EndIf $soundplay = _SoundPlay($sound, 1) _SoundClose($sound)SO HERE IS THE SCRIPT, WHEN I USE IT THE MUSIC PLAYS BUT YET I HAVE A PROBLEM, THE program HAS A PROBLEM AND IT SHOWS ME THE (NOT RESPONDING) LABEL AND I CAN'T DO ANYTHING.PLEASE HELP ME WITH MY SCRIPTHOW DO _sound open, _soundplay and _soundclose MUST BE IN ORDER TO WORK PERFECT? Link to comment Share on other sites More sharing options...
Developers Jos Posted May 2, 2007 Developers Share Posted May 2, 2007 (edited) Since we are shouting : RTFM $fWait [optional] This flag determines if the script should wait for the sound to finish before continuing: 1 = wait until sound has finished 0 = continue script while sound is playing (default) And NO need to create two threads with the same question. *click* Edited May 2, 2007 by JdeB SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Recommended Posts