View Full Version : Dynamic DLL load error
MarkRiffey
06-08-2020, 03:06 PM
Friedrich,
I dont see this error number in the documentation. Any idea what this means? GetPCC.dll is a Clarion dll that the installer calls.
Mark
4996
linder
06-09-2020, 01:42 AM
Hi Mark,
this seems to be a custom message box. What command did you use to catch the "error code"?
The "Load DLL..." script function only returns the following:
If the function succeeds, the %_SB_ERRORCODE% return value is nonzero.
If the function fails, the return value is zero.
The %_SB_ERRORCODE% value is retrieved from the LoadLibrary Windows API.
Friedrich
MarkRiffey
06-09-2020, 09:26 AM
Friedrich,
It looks like this:
There was a fatal error when trying to launch the Product Control Code
entry subsystem. This installation program must halt.
The module "GetPCC" returned errorcode : %_SB_ERRORCODE%
Please advise ENERCALC that this problem happened and provide
the errocode given above.
Send information to support@enercalc.com
See image below.
Mark
4997
linder
06-11-2020, 02:55 AM
Hi Mark,
this error code comes directly from the LoadLibrary Windows API call. It is GetLastError() 87:
ERROR_INVALID_PARAMETER 87 (0x57) - The parameter is incorrect.
Friedrich
MarkRiffey
06-18-2020, 02:14 PM
this error code comes directly from the LoadLibrary Windows API call. It is GetLastError() 87:
ERROR_INVALID_PARAMETER 87 (0x57) - The parameter is incorrect.
Friedrich,
I dont think we use that in our DLL, but I'll check.
Mark
MarkRiffey
06-18-2020, 02:23 PM
Friedrich,
Checked the source, it doesn't call LoadLibrary directly. I suppose it's possible that one of these does, however. You might recognize a few of them:)
Mark
MODULE('CLARUN.LIB')
CRC32(*STRING buffer,ULONG buffersize,ULONG seed),ULONG,RAW,NAME('Cla$crc32')
END
MODULE('win32.lib')
OutputDebugString(*CString),raw,pascal,name('Outpu tDebugStringA')
END
MODULE( 'LSMEMORY.LIB' )
LS_INIT( ULONG, ULONG ),LONG,RAW,PASCAL
LS_KILL(),RAW,PASCAL
LS_MEMCOMPRESS( *CSTRING, *CSTRING, *CSTRING ),LONG,RAW,PASCAL
LS_MEMDECOMPRESS( *CSTRING, *CSTRING, *CSTRING ),LONG,RAW,PASCAL
LS_ORIGINALSIZE(),LONG,RAW,PASCAL
LS_COMPRESSEDSIZE(),LONG,RAW,PASCAL
END
linder
06-19-2020, 10:58 AM
Hi Mark,
the installer has to use LoadLibrary Windows API when you call your DLL from within the installer. And this call fails.
Before the installer can call a function from within your DLL, it has to load it using the LoadLibrary Windows API. The installer is not even processing your DLL at this stage. It just uses the Windows API to load your library.
Friedrich
MarkRiffey
06-19-2020, 04:42 PM
Friedrich,
I had a feeling that's what was going on. Not the first time, wont be the last:)
Mark
Powered by vBulletin® Version 4.2.5 Copyright © 2024 vBulletin Solutions Inc. All rights reserved.