AutoitHacks

Play Sound From Binary - au3 Script

Mar 27th, 2012
390
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
AutoIt 0.62 KB | None | 0 0
  1. ;---------------------------------------------
  2. ;           www.AutoitHacks.tk
  3. ;---------------------------------------------
  4. #Region ;**** Directives created by AutoIt3Wrapper_GUI ****
  5. #AutoIt3Wrapper_outfile_type=a3x
  6. #AutoIt3Wrapper_Compression=4
  7. #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
  8. HotKeySet("{ESC}","_Exit")
  9.  
  10. $H = DllStructCreate('byte['&Sound(1)&']')
  11. DllStructSetData($H,1,Sound())
  12. DllCall('winmm.dll', 'int', 'PlaySoundW', _
  13.     'ptr', DllStructGetPtr($H), _
  14.     'ptr', 0, _
  15.     'dword', 8197)
  16.  
  17. Sleep(118000)
  18.  
  19. Func _Exit()
  20.     Exit
  21. EndFunc
  22. ;---------------------------------------------
Advertisement
Add Comment
Please, Sign In to add comment