Click or drag to resize
ManipulateEndOf Method (DateTime, DateTimeParts)
Get the end of part from DateTime.UtcNow. E.g. EndOf(DateTimeParts.Year) return a new DateTime at the end of the current year.

Namespace: MomentSharp
Assembly: MomentSharp (in MomentSharp.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax
public static DateTime EndOf(
	this DateTime dateTime,
	DateTimeParts part
)

Parameters

dateTime
Type: SystemDateTime
this DateTime
part
Type: MomentSharpDateTimeParts
DateTimeParts

Return Value

Type: DateTime
DateTime at the end of give part

Usage Note

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