Hi,
I would like to use a float property in my component, but set it to some non-zero default value (let's say it is 1000.0). If I try to do this in the Create, the property start to behave wildly since the default value for floats it 0 (see classes.TWriter.WriteProperty.WriteFloatProp.IsDefaultValue) so when I override some value with 0 in the form designer, delphi doesn't save this value (it's default in this case), but my Create will set it to 1000.0 when the compoent will be loaded the next time, so the actually I have the value I didn't set.
The problem is that there is no way to set default with 'default' directive (the compiler says 'Default values must be of ordinal, pointer or small set type') and it's also not possible to force storing with stored directive, it doesn't work (Delphi 5)
So is there a chance to find a workaround?
Thanks,
Max