From Appmethod Libraries
Jump to: navigation, search

Object Pascal

property AsBCD: Currency read GetAsBCD write SetAsBCD;


__property System::Currency AsBCD = {read=GetAsBCD, write=SetAsBCD};


Type Visibility Source Unit Parent
property public
Data.DB TParam


Specifies the value of the parameter when it represents a binary-coded decimal (BCD) field with less than 4 decimal places or 20 significant digits.

Set AsBCD to assign the value for a BCD field to the parameter when the BCD field can be converted to the Currency type without a loss of precision. TBCDField objects use the Currency type to represent the value of BCD fields, so AsBCD takes a Currency value as well. Setting AsBCD sets the DataType property to ftBCD.

Read the AsBCD property to determine the value that was assigned to an output parameter, represented as a Currency type. The value of the parameter is converted to a Currency value if possible.

Tip: If the BCD field requires greater precision than allowed by the Currency type, use a TFMTBCDField object and the AsFMTBCD property instead.

See Also

Code Examples