Win32 - Open a console any play a wavefile

Share your advanced PureBasic knowledge/code with the community.
va!n
Addict
Addict
Posts: 1104
Joined: Wed Apr 20, 2005 12:48 pm

Win32 - Open a console any play a wavefile

Post by va!n »

Code updated For 5.20+

just a small example how to open a console and play a wavefile ;-)

Code: Select all

-----------------------------------------------------------------------------------------------------------------------
;
; Open a console and play a wavefile! - Win32 example by Mr.Vain/Secretly! (Thorsten Will) 
;
; (20-October-2005 - 01:08)   v0.01
;
;-----------------------------------------------------------------------------------------------------------------------

OpenConsole()
PrintN("Nice way to play a wavefile in a console ;-)")

cFile.s = "Welcome2PureBasic.wav"
sndPlaySound_(@cFile,#SND_SYNC)
Sleep_(1000)
End
You can donwload the example including a small nice wavefile ;)
Download
va!n aka Thorsten

Intel i7-980X Extreme Edition, 12 GB DDR3, Radeon 5870 2GB, Windows7 x64,
Bonne_den_kule
Addict
Addict
Posts: 841
Joined: Mon Jun 07, 2004 7:10 pm

Post by Bonne_den_kule »

Oooo!
This was advance ;)
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Post by ts-soft »

Very good wavefile :wink:
PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
va!n
Addict
Addict
Posts: 1104
Joined: Wed Apr 20, 2005 12:48 pm

Post by va!n »

@Bonne_den_kule
@ts-soft:
:wink: thanks
va!n aka Thorsten

Intel i7-980X Extreme Edition, 12 GB DDR3, Radeon 5870 2GB, Windows7 x64,
Post Reply