buzz44 Posted March 25, 2005 Share Posted March 25, 2005 (edited) SoundPlay ("C:\blah\blah.mid") $LTJB = MsgBox (4, "Blah", "Blah" ) If $LTJB = 7 Then Exit EndIf ;Script then continouesThe above scripts plays a sound file and pops a msg box up, if u Click No or close the msgbox the sound will stop playing because autoit3 isnt running anymore, but if u click yes the sound will continue to play Is there a way i can stop the sound without closing the msg box or clicking "no"? i want it to be able to stop when "yes" is pressed Edited March 25, 2005 by burrup qq Link to comment Share on other sites More sharing options...
Somerset Posted March 25, 2005 Share Posted March 25, 2005 the only way to stop a file from playing is terminating the script. are you wanting to carry on with the script while the sound is going? or just stop the sound to start another? Link to comment Share on other sites More sharing options...
buzz44 Posted March 25, 2005 Author Share Posted March 25, 2005 If "yes" OR "no" is clicked it will stop the sound clicking no closes the script clicking yes continues the script qq Link to comment Share on other sites More sharing options...
Somerset Posted March 25, 2005 Share Posted March 25, 2005 SoundPlay ("entertanr.mid") $LTJB = MsgBox (4, "Blah", "Blah" ) If $LTJB = 7 Then SoundPlay ("null") EndIf sleep(10000) ;Script then continoues instead of exit i just executed soundplay again on a file that doesn't exist. it stops the sound right now. then i added the delay to see if it truly ended and yeah it did. Link to comment Share on other sites More sharing options...
buzz44 Posted March 25, 2005 Author Share Posted March 25, 2005 ahhh very good... ty. I think they should include that in the help file qq Link to comment Share on other sites More sharing options...
Wb-FreeKill Posted March 25, 2005 Share Posted March 25, 2005 ahhh very good... ty. I think they should include that in the help file <{POST_SNAPBACK}>Ahh nice, i needed it too... yeah somethings missing in the helpfile about this func.. Link to comment Share on other sites More sharing options...
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