怎样在主窗口中加载WAV声音文件呀?
我知道
begin.wav在当前目录下
----------resource.h-------------
#define ID_WAVE 2000
----------script.rc-----------------
#include "resource.h"
ID_WAVE WAVE begin.wav
--------main.cpp-----------
int WINAPI WinMain(HINSTANCE hInstance,HINSTANCE hPrevInst,LPSTR lpszCmdLine,int nCmdShow)
{
...
hInstance_app=hInstance;
...
}
case WM_CREATE:
{
PlaySound(MAKEINTRESOURCE(ID_WAVE),hinstance_app,SND_ASYNC|SND_RESOURCE);
}
它提示的错误是 24 E:\TEXT\c++\program design\API\main.cpp `hInstance_app' undeclared (first use this function)
没定义 用 HINSTANCE hInstance_app=hInstance; 也不行
高手教教菜鸟啊~