IUnitOfMeasureExtensionsRoundValue Method |
Rounds the specified value according to the rounding rules of the unit of measure.
Namespace:
Aloe.EnterpriseOne.Model.Core.Metrics
Assembly:
Aloe.EnterpriseOne.Model (in Aloe.EnterpriseOne.Model.dll) Version: 20.1.3.5
Syntaxpublic static decimal RoundValue(
this IUnitOfMeasure unit,
decimal value,
MidpointRounding mode = 1
)
<ExtensionAttribute>
Public Shared Function RoundValue (
unit As IUnitOfMeasure,
value As Decimal,
Optional mode As MidpointRounding = 1
) As Decimal
public:
[ExtensionAttribute]
static Decimal^ RoundValue(
IUnitOfMeasure^ unit,
Decimal^ value,
MidpointRounding^ mode = 1
)
[<ExtensionAttribute>]
static member RoundValue :
unit : IUnitOfMeasure *
value : decimal *
?mode : MidpointRounding
(* Defaults:
let _mode = defaultArg mode 1
*)
-> decimal
Parameters
- unit
- Type: Aloe.EnterpriseOne.Model.Core.MetricsIUnitOfMeasure
The unit of measure, which specifies the rounding rules. - value
- Type: SystemDecimal
The value to round. - mode (Optional)
- Type: SystemMidpointRounding
The midpoint rounding mode.
Return Value
Type:
DecimalThe rounded value.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
IUnitOfMeasure. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
See Also