Subj : Re: 32Bit DLL Call To : borland.public.cpp.borlandcpp From : Ed Mulroy [TeamB] Date : Tue Jan 11 2005 03:02 pm It works pretty much the same in 5.51 (C++ Builder 5.0 command line tools) as it does with BC++ 4.5 on up. Tell him to run this command (substituting the correct file name) impdef DllName.DEF DllName.DLL Afterwards have him pull up the *.DEF file into an editor and look at the actual text of the name corresponding to the function name. Assuming that the source code name is FuncName then, depending upon the actual text of the function name in the DEF file, the function prototype would probably be like this: if it is _FuncName #ifdef __cplusplus extern "C" #endif int __declspec(dllimport) FuncName(StructType *s1, StructType *s2, StructType *s3); if it is FuncName #ifdef __cplusplus extern "C" #endif int __declspec(dllimport) WINAPI FuncName(StructType *s1, StructType *s2, StructType *s3); If the compiler does not recognize any one or more of __declspec, dllimport or WINAPI then tell him that #include should be at the top of his source file. If the error is that the function is not found then have him add the *.DEF file to the ilink32.exe command line or create an import library and add that to the bcc32 or ilink32 command line. He can create the import library with a command like this: implib -c DllName.LIB DllName.DLL .. Ed > Michael Shohoney wrote in message > news:41e42c8f$1@newsgroups.borland.com... > > I don't have 5.5 (I still use an oldie) but have someone I am > trying to help call a 32-bit DLL from 5.5. Can someone > supply a snipet that would accomplish this? The DLL takes > four pointers to four separate data structures as arguments > (i.e. DLL(&struct1, &struct2, &struct3, struct4); ). .