Click or drag to resize

ExtensionsIntervalRoundAway Method

Rounds a given number to the closest interval away from zero.

Namespace: RAYLASE.Shared
Assembly: RAYLASE.Shared (in RAYLASE.Shared.dll) Version: 2.19.0
Syntax
C#
public static long IntervalRoundAway(
	this double number,
	int interval
)

Parameters

number  Double
The number to round.
interval  Int32
The interval for rounding.

Return Value

Int64
The rounded number.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Double. 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