I have an aplication which used to be created in Delphi 5. For various
reasons we want to try to recode that in vb .net but the original
application called functions inside one or more dlls that were loaded
dynaically by the name found at run time.
i.e. what would happen is that the application would start, it finds
all the *.dll functions available in a specified subdirectory.
The user would then select one target platform which corresponds to
one DLL from the found DLL list
That DLL is then loaded dynamically and used by the application.
The rationale is that the application then automatically picks up new
target platforms simply by adding the DLL to the appropriate
directory.
I am having problems trying to get this to run in vb .net. I can get a
single DLL to work but have to explicitly name the DLL in the source
code. In delphi I would call LoadLib and GetProcAddress and then cast
the result of GetProcAddress to a pointer to a function which would
then be used by the application. Very simple and it works. This
appears to be impossible in VB .net
Is there any way to achieve this?