Hello,
Can anybody tell me how to execute a procedure that you pass as a parameter?
I have:
type DBproc = procedure();
procedure DBUpdateProcedure(a_procedure: DBproc);
begin
{statements}
a_procedure;
end;
procedure proc_a();
begin
{statements}
end;
Then I would like to execute proc_a like this:
DbUpdateProcedure(proc_a());
I can't compile this, the error I get is: Incompatible types: 'DBproc' and 'procedure, untyped pointer or untyped parameter'
I hope that anybody knows how to solve this.
Thanx in advance!
Can anybody tell me how to execute a procedure that you pass as a parameter?
I have:
type DBproc = procedure();
procedure DBUpdateProcedure(a_procedure: DBproc);
begin
{statements}
a_procedure;
end;
procedure proc_a();
begin
{statements}
end;
Then I would like to execute proc_a like this:
DbUpdateProcedure(proc_a());
I can't compile this, the error I get is: Incompatible types: 'DBproc' and 'procedure, untyped pointer or untyped parameter'
I hope that anybody knows how to solve this.
Thanx in advance!