# 几个基本指令

Posted by 纪文和 on October 13, 1999 at 14:27:50:

In Reply to: 如何用 Windows API停止正在播放的Wav? posted by ComBilLi on October 13, 1999 at 13:46:22:

: 小弟初学Win API，我用Winmm.dll来播放Wav档，在播放中途不知如何停止。
: 请指教。

以下是几个基本指令:

开启:i = mciSendString("open c:\sound.wav type waveaudio alias voice1", 0&, 0, 0)

播放:i = mciSendString("play voice1", 0&, 0, 0)

暂停:i = mciSendString("pause voice1", 0&, 0, 0)

停止:i = mciSendString("stop voice1", 0&, 0, 0)

重播:i = mciSendString("resume voice1", 0&, 0, 0)

VB入门网

Follow Ups: