Calling external Functions with System::Call
Hi, I have a problem using a function in a third Party-dll. In fact I have two problems ;-)
1. I do not have a documentation about the external lib.
2. I dont understand the syntax of the System::Call call.
but I have found an example Install Shild Script where the functions I have to call, are used. So maybe anyone of you can help me with that. Ok, lets start with the three functions I have to call:
in install script they are defined the following:
prototype gptsbinstlms11.GlmsPMKVerify_32( POINTER, BOOL, POINTER, POINTER, POINTER);
prototype gptsbinstlms11.GlmsFileSetupKeys(POINTER, POINTER, POINTER);
prototype gptsbinstlms11.GlmsPrdInstallSetup(POINTER, int, POINTER, POINTER);
And here is a function which calls the functions in the dll (also from install shild)
function BOOL CreateGLMSFile(szInstallDir,szValue)
string svName,svInstallDir,svValue;
POINTER pvInstallDir,pvPMCKey;
number ipRefCount;
long lvPrdInstallSetup;
number nvRetSetupKey;
begin
if UseDLL( GLMSSBInst10 ) != 0 then
MessageBox("Failed to load " + GLMSSBInst10, SEVERE);
return FALSE;
endif;
svName = LICENSEAPPNAME;
//nvSize = -1;
svValue=szValue;
svInstallDir = szInstallDir;
pvInstallDir = &svInstallDir;
nvRetSetupKey=GlmsFileSetupKeys(&svName,&svValue,pvInstallDir);
if(nvRetSetupKey=-1) then
return FALSE;
endif;
ipRefCount = 1;
pvPMCKey = &svValue;
pvInstallDir = &svInstallDir;
lvPrdInstallSetup = gptsbinstlms11.GlmsPrdInstallSetup(pvPMCKey,
&svName, ipRefCount, pvInstallDir);
if(lvPrdInstallSetup!=94555) then
return FALSE;
endif;
if UnUseDLL( GLMSSBInst10 ) != 0 then
MessageBox("Failed to unload " + GLMSSBInst10, SEVERE);
return FALSE;
endif;
return TRUE;
Thanks for any advise or help you can give.
Marco