DLL: Registering Functions

I am thinking about a kind of Plugin System to extend the Script-functions without recompiling the Application.

My Idea is, during the startup, the programm scans a folder and registers all found DLLs.
(Each DLLs exposes one Function).

As it is not known in which DLL a function is defined, I can not use
Function FindWindow(c1, c2: PChar): Cardinal; external ‘FindWindow@user32.dll stdcall’;
which is in one of the examples.

May somebody has any Ideas how to achieve this?

Greetings - Klaus

You can’t really, from the outside of a dll you can’t figure out what the signature of a function would be.