Subject Re: [IBO] about external functions
Author Geoff Worboys
> is IB integer 4 bytes-length like in delphi?
> as i know it is, so where is the problem?

Check your declarations. You had...

function Test(a: Integer): Integer; stdcall;

Interbases passes all variables by pointer (reference for you
Pascalites). I did not notice this before. You should have...

function Test(var a: Integer): Integer; cdecl; export;


The last bit (cdecl; export;) I copied out of the freeudflib, so I
assume this is correct. I expect that IB is expect parameters
handling in C-style and not Pascal style. Since I use C for my UDFs I
am a bit hazy on the details for building with Delphi - which is why I
suggest you look carefully at the free samples available.

HTH

Geoff Worboys
Telesis Computing