System.Variant.operator %

From RAD Studio API Documentation
Jump to: navigation, search

C++

Variant __fastcall operator %(const Variant& rhs) const;
Variant __fastcall operator %(const AnsiString& rhs) const
Variant __fastcall operator %(int rhs) const
Variant __fastcall operator %(double rhs) const

Properties

Type Visibility Source Unit Parent
function public sysvari.h System Variant


Description

Returns the remainder from dividing the Variant's value by a specified value.

The operator % returns a new Variant that is the modulus of this Variant and rhs.

If the operation is not possible because of an invalid variant type conversion, an System.SysUtils.EVariantError exception is thrown.

Note: Do not call the % operator directly. It is an overload of the compiler modulus operation.

See Also