Answer the question
In order to leave comments, you need to log in
Is there an alternative to Delphi Invoke for FreePascal?
Good afternoon!
I am looking for a way to call to do the following:
There is a set of functions, procedures, methods, constructors with different set of parameters, type, etc.
// например:
function Fn1(param: Integer; param2: String): Byte;
function Fn1(param: TPoint): String;
procedure Fn1(param: Object);
//...
byteVar := Fn1(1, 'hello');
function CallFn(FnPointer: pointer; Args: array of Variant): Variant;
// ...
ResultValue := CallFn(@MessageBox, [0, 'hello', 'world', '0']);
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question