On 18 Mar 2002 at 13:42, Anuradha wrote:
Hello ,
It gives us 264 as size and capacity is 0.
Hmmm ... the capacity (AFAIK) should not be 0. I thought GPC defaults to a capacity of 255 when no capacity is supplied?
we have gpc-20010924.Is it corrected in a newer version?
Apparently. But I think you need to correct it in your code. It is not a good idea to declare a string field in a record without specifying the size/capacity of the string. Basically, it means that you are leaving it to someone else (e.g., the compiler) to determine the size of your record - and it may decide on a size that is different from the one you would like (as seems to have beem done here).
Something like this would be a better solution, should work with all compilers, and should solve your specific problem;
type myrec = record st : string [128]; end;
Best regards, The Chief -------- Prof. Abimbola A. Olowofoyeku (The African Chief) web: http://www.bigfoot.com/~African_Chief email: African_Chief@bigfoot.com