[simpits-tech] OT: Delphi Record problems
Stig Joergensen
simpits-tech@simpits.org
Sat, 21 Dec 2002 16:51:33 +0100
Sorry for the OT, but i have a problem i Delphi, and some of you might
know the answer
I have a problem with record that i for the life of me can not get a
handle on:
say i have a file that are organized like this
0000000100000001abcdefgh0000000311111111222222223333333300000000........
.
i have create a record that match the above
TMYRec = packed record
type : integer;
size : integer;
name : array[0..7] of char
count : integer;
numbers : array of integer
state : integer;
...
...
...
end;
myrec : TMyRec;
so i set the size of "numbers" to the "count", one would hope that the
sizeof(MyRec) would reflect the change, but this is not the case, which
leaves me to beleave that the "numbers" is just a pointer....
any idea how i can expand the "numbers" at runtime to reflect the
content of the file?
/Stig
------------------------ Yahoo! Groups Sponsor ---------------------~-->
Get 128 Bit SSL Encryption!
http://us.click.yahoo.com/CBxunD/vN2EAA/xGHJAA/i7folB/TM
---------------------------------------------------------------------~->
The Delphi Collection Web Site!
http://www.delphicollection.com/public/index.shtml
---------------------------------------------------------------
Unsubscribe:delphi-programming-unsubscribe@yahoogroups.com
List owner:delphi-programming-owner@yahoogroups.com
---------------------------------------------------------------
Your use of Yahoo! Groups is subject to
http://docs.yahoo.com/info/terms/