but i want :
calling dll from another dll
for example
i have
fifa.dll her fuctions is
string version(string name,int date);
i want to call this function from another dll,but in delphi
i want to hide this function in another dll for example or i rename it
thank you
yes my dear 7bit, it is created by c++
fifa.dll is created by C++;
function version(name: PChar; date: Integer): PChar; external "fifa.dll"; cdecl;
or
function version(name: PChar; date: Integer): PChar; external "fifa.dll"; stdcall;
depends on whether the dll is cdecl (probably) or stdcall (mostly only winapi dlls)
put this line into your interface section and you can use the function.
But you have to take care who is responsible for freeing (or supposed to free) the memory that is used for the strings. You could accidentally create a memory leak here if you don't know exactly what is going on and how the function is supposed to be used and who owns the strings.
thank you 7bit you are very great delphi devloper
pls i am a rigth ?
library Project2;
uses
SysUtils,
Classes;
function version(name: PChar; date: Integer): PChar; external "fifa.dll"; stdcall;
function vvv(name: PChar; date: Integer): PChar; stdcall;
begin
Result :=version(name;500);
end;
exports
vvv;
begin
end.
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
hello
pls help me
i have a dll,
i want to create dll,how i can call fuctions of frist dll from my dll
I am a delphi developer
pls help me by example
thank you