Neil Santos wrote:
RRecdStream = record { pointer to the structure to be written } recd_ptr = pointer; { byte; denotes what kind of structure is held by recd_ptr } recd_type = TRecordType; { MAX_PATH_LEN is 2060 bytes; as defined in GPC 20030830. Is there any way to retrieve this at runtime? } file_name = string(MAX_PATH_LEN); end;
GPC doesn't declare MAX_PATH_LEN. Perhaps it's a predefined system macro on your system, but it's not recommended to use those.
Usually I'd just use `TString' (which has a reasonably large dimension).
And, oh, is there any way to turn a constructor into a function? :P
You can use any constructor as a Boolean function. It will return False if the constructor calls Fail, otherwise True. Is that what you mean?
Frank