>>
APLDN Home

>>
Events

>>
Trainings

>>
APL Books

>>
APLDN Links

>>
Discussion Groups

>>
Downloads

>>
Articles

>>
Library

>>
Learning Tools

>>
APLDN User IO

>>
APL2000.com




General

Author Thread: ADF files and DLLs
Ken.Travers
ADF files and DLLs
Posted: Sunday, February 04, 2007 9:49 PM (EST)

May I please ask help with three questions:

(1)  In defining a DLL entry point in my ADF definitions, when I use the LIB option, do I specify it thus:

      LIB E:\xxx\yyy\dllname

or thus:

      LIB E:\xxx\yyy\dllname.DLL

 

(2)  If I specify a DLL file name without a path, where does the system look for the DLL file?

 

(3)  When I get the message "Unable to load DLL  ...  ...  reason 14001", what is the code 14001 trying to tell me?

 

Please forgive my ignorance, but I've had very little experience with ADF definitions.

 


Comments:

Author Thread:
Support
ADF files and DLLs
Posted: Monday, February 05, 2007 12:59 PM (EST)

(1)  The .DLL extension is optional.


(2)  The search order should be: 

       1. The Windows system folder.
       2. The folder in which the executable was loaded.
       3. The current folder.
       4. The Windows folder.


(3)  The command:   ]emsg 14001  reports the Windows error message as "This application has failed to start because the application configuration is in correct. Reinstalling the application may fix this problem.", which is related to the message in the original error report.  Just as a test, see if the DLL can be loaded from APL+Win with

      ŒWCALL 'LoadLibrary' dll

 

If a value (handle) other than 0 is returned, the DLL successfully loaded in which case the problem isn't likely to involve the location of the DLL but elsewhere like the WCALL defintion itself.  Remember to call

       ŒWCALL 'FreeLibrary' handle  

to unload the DLL.


APL2000 Support

     

Ken.Travers
ADF files and DLLs
Posted: Sunday, February 11, 2007 7:33 PM (EST)

Thank you for the speedy response and for your suggestion.

The attempt to load the DLL using quad-WCALL 'LoadLibrary' actually fails.  As the return code is zero, rather than a Windows handle, how do I find the reason for the failure to load?

Ken T.

 

     

davin.church
ADF files and DLLs
Posted: Monday, February 12, 2007 4:44 PM (EST)

Right after it fails, use:

 

Œwcall 'GetLastError'

 

to give the return code.  ]EMSG can then turn that into a text error message.

     

Ken.Travers
ADF files and DLLs
Posted: Monday, February 12, 2007 5:05 PM (EST)

Thank you Davin.  Obviously I'm quite rusty on this stuff!

Ken T.

 

     



APL2000 Official Web Site

The influence of each human being on others in this life is a kind of immortality.
--- John Quincy Adams

APLDN Home   |    |  Events   |  Trainings   |  APL Books   |  APLDN Links   |    |  Discussion Groups   |    |  Downloads   |  Articles   |  Library   |  Learning Tools   |  APLDN User IO   |  APL2000.com   |