2009/1/20 Darmawan Sugiarto <[email protected]>: > Can you give more information about your function.
Sure: function FieldValueAsString(var fsbuffer: TByteBuffer; fitype,marker,fisize: integer): string; begin case fitype of 43,52,108:Result:=inttostr(LEtoN(PLongint(@fsbuffer[marker])^)); 50:Result:=inttostr(LEtoN(PSmallInt(@fsbuffer[marker])^)); end; end; It was failing before it got there, so I don't think the problem was with the function. In any case, Martin's suggestion regarding calling the ReadBuffer function with the first element of the array rather than the pointer has worked... _______________________________________________ Lazarus mailing list [email protected] http://www.lazarus.freepascal.org/mailman/listinfo/lazarus
