Tech Support > Microsoft Windows > Development Resources > ASPI
ASPI
Posted by jeje on December 2nd, 2003


Hello I'm trying to use ASPI library from Adaptec to verify raid system. I
can't use the API function bvecause I have error on compilation.link Can't
convert from "FARPROC" on the GetProcAddress(
hWNASPI32,"GetASPI32SupportInfo") call.
If anybody can help me to use this library...
thanks




Posted by bunny on December 2nd, 2003


jeje wrote:

you need to cast the return value from GetProcAddress to the correct
function pointer type. ie something like:

// function pointer for some aspi function
typedef void (*ASPI_PROC)(ASPI_CDB *arg1);

// get the aspi function from the DLL
ASPI_PROC aspi_proc = reinterpret_cast<ASPI_PROC>(GetProcAddress(hdll,
"TheAspiExport"));



Similar Posts