Subject | Re: [IBO] OnAfterModify event fire twice if using IB_Column.AsVariant |
---|---|
Author | Helen Borrie |
Post date | 2005-02-14T00:38:48Z |
At 04:10 PM 13/02/2005 +0100, you wrote:
request.
the Value property? It will trip any necessary type validation, as
required, and avoid exceptions on nulls...
Helen
>OnAfterModify event fire twice if using IB_Column.AsVariant:Why? AsVariant has to test and perform two conversions. You get what you
>
>- first when setting the field as not Null
>- second when setting the value of the field
>
>IB_Column.AsString work as expected - fire only once
>
>IB_Column.AsVariant := 'test';
>and
>IB_Column.AsString := 'test';
>
>should behave the same.
request.
>The logic of setting a variant value (and TIB_Column.Assign(TIB_Column))I'm curious as to why you need to use AsVariant at all. Why not just use
>should be changed.
the Value property? It will trip any necessary type validation, as
required, and avoid exceptions on nulls...
Helen