Ok the first question should be an easy on to answer but i have never try to do it before so i dont know what i need to do...

First off i want to build a program that can take and use plugins made for it.... I would like to have the program look into a directory and grab a list of all dlls... i dont know how to do that so if you could help me out there...

i know to make a plugin system work i have to have a default PROC to be called on... it is possible to have the program grab the needed info from that proc or will i have to have a plugin ini like for 3D Studio Max..
Posted on 2003-09-18 02:37:21 by devilsclaw
Use the FindFirstFile and FindNextFile API in a loop to build your DLL list.
Then for each DLL filename call LoadLibrary and pass the returned handle to GetProcAddress, specifying the name or ordinal of the exported procedure according to your plugin specifications. If the procedure doesn't exist then be sure to call FreeLibrary on the module.

Consult the platform SDK on these APIs.
Posted on 2003-09-18 03:18:00 by iblis
You might want to take a look at Ketil's AddInManager DLL. It is available with source code from his RadASM site. The "ListDlls" procedure does exactly that. If your DLL has a predefined procedure that returns the info you need you can get the information as you build the list by loading the DLL then calling the procedure.
Posted on 2003-09-18 03:44:54 by donkey
thanks both of you i will try them both..
Posted on 2003-09-18 03:59:24 by devilsclaw