At 2:26 AM -0700 5/25/99, Danko Radic wrote:
>It might sound silly (and I might slipped something from manual) but how
>to determine size of the DM record (what's the best way)?

MemHandleSize or MemPtrSize.


>Second: I'd like to make sure if Dm record attached to text field (Fld) is
>resized AUTOMATICALLY when I write into field and close that field. It
>acts as if it is (I create small record and write more text than it's
>size is into field, and it's stored well). I'd just like someone who knows
>for sure to say if that's correct or not.

Fields grow their allocations as text is added. Currently, they grow by 1/5th of the total size or by 16 bytes, whichever is larger, up to the maxChars value set by FldSetMaxChars. You can use FldCompactText to tell a field to trim any unused space out of it's allocation, so that the NULL at the end of the field text is the last byte in the text-related part of the allocation.

Fields are "smart" about growing--you can grow a field that is in the middle of a database record, and the field code will grow the entire record, moving non-field data after the text if necessary.

--Bob

Reply via email to