[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] Reference for unit 'DB' (#fcl)

TField.AsBoolean

Access the field's contents as a Boolean value.

Declaration

Source position: db.pas line 404

public property TField.AsBoolean : Boolean
  read GetAsBoolean
  write SetAsBoolean;

Description

AsBoolean can be used to read or write the contents of the field as a boolean value. If the native type of the field is not Boolean, then an attempt will be made to convert the field value from the native format to a boolean value when reading the field's content. Likewise, when writing the property, the value will be converted to the native type of the field (if the value allows it). Therefor, when reading or writing a field value for a field whose native data type is not a Boolean value (for instance a string value), an exception may be raised.

See also

TField.Value

  

Value of the field as a variant value

TField.AsInteger

  

Access the field's contents as a 32-bit signed integer (longint) value.


Documentation generated on: May 14 2021