VB播放wav资源文件

页面导航:首页 > 软件编程 > vb.net > VB播放wav资源文件

VB播放wav资源文件

来源: 作者: 时间:2016-01-18 16:54 【

VB播放wav资源文件:Private Declare Function sndPlaySound Lib winmm.dll Alias sndPlaySoundA (lpszSoundName As Any, ByVal uFlags As Long) As LongPrivate Const SND_ASYNC = H1 ls...

VB播放wav资源文件:
Private Declare Function sndPlaySound Lib “winmm.dll” Alias “sndPlaySoundA” (lpszSoundName As Any, ByVal uFlags As Long) As Long
Private Const SND_ASYNC = &H1          ‘将控制权立即转让给程序
Private Const SND_NODEFAULT = &H2 ‘不使用缺省声音
Private Const SND_MEMORY = &H4     ‘指向一个内存文件
Private Const SND_LOOP = &H8            ‘循环播放
Dim B() As Byte

Private Sub Form_Load()
B = LoadResData(101, “CUSTOM”)
sndPlaySound B(0), SND_ASYNC Or SND_NODEFAULT Or SND_MEMORY Or SND_LOOP
End Sub

本文来自: 雪域博客

Tags:

文章评论

最 近 更 新
热 点 排 行
Js与CSS工具
代码转换工具

<