Record with string size

From: BedBaol (bedrosianbed_at_hotmail.com)
Date: 12/30/04


Date: Thu, 30 Dec 2004 13:28:47 GMT

Hello.
How can I compute record size if Record contains string?
Say:

type
TMyRecord = record
      Number: integer;
      Logical : boolean;
      Text : string;
      end;
var
   MyRecord: TMyRecord;

I see that SizeOf(MyRecord) computes string size everytime equal to 4
(pointer size).
I don't want to fix sting part of record, because it changes very much at
runtime...
Thanks.

  BedBaol



Relevant Pages

  • D8.NET: FillChar
    ... What is the best equivalent of the folling use of FillChar in D8.NET? ... b: String; ... Sub: TMySubRecord; ... MyRecord: TMyRecord; ...
    (borland.public.delphi.nativeapi)
  • Re: Type record recursion
    ... DisplayName: string; ... type TMyRecordArray = array of TMyRecord; ... SubItems: TMyRecord; ...
    (alt.comp.lang.borland-delphi)
  • Re: Record with string size
    ... BedBaol wrote: ... > How can I compute record size if Record contains string? ... > TMyRecord = record ... may be shared by multiple string variables. ...
    (alt.comp.lang.borland-delphi)
  • Re: Calculate the string statement
    ... verkn:(vkn:char; ... funkt:(fkt:string; ... var fkt,dfkt: p; ... var fehler: boolean; ...
    (comp.lang.pascal.borland)
  • Two new tests for MM B&V
    ... var RunningThreads: Integer; ... class function TStringThreadTest.GetBenchmarkDescription: string; ... function CheckPattern(const Dest: Pointer; const Size: Integer; const ...
    (borland.public.delphi.language.basm)