// build with VC++6 as a console app
// link to: msacm32.lib
// include: windows.h, mmreg.h, msacm.h, stdio.h
BOOL driverEnum(HACMDRIVERID hadid,DWORD dwInstance,DWORD fdwSupport) {
printf("hadid=%d\n",(int)hadid);
return TRUE;
}
void main(void) {
MMRESULT mmr;
mmr=acmDriverEnum((ACMDRIVERENUMCB)driverEnum,0,0);
if(!mmr) {
printf("error!\n");
}
}
The program compiles and links nicely, but when I'm trying to start the program, problems occur -- ACM continues to call driverEnum() with the same HACMDRIVERID... And when trying to make driverEnum() return FALSE to stop the enumeration, a nice general protection fault pops up...
Can someone tell me what I'm doing wrong?
--
mvh Rasmus
Edited by - kadaf on April 28, 2001 12:41:52 PM
ACM problem...
I have a problem with making my Win32 programs using the ACM API... The following code is (I think) the minimal ACM program. It's purpose is to enumerate ACM drivers installed on the system.
-- Rasmus Neckelmann
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement