Method TruncateToHours
TruncateToHours(DateTime)
Returns a new System.DateTime value equivalent to the one provided but with zero minute, second, and millsecond components.
Declaration
public static DateTime TruncateToHours(this DateTime value)
Parameters
| Type | Name | Description |
|---|---|---|
| System.DateTime | value | The System.DateTime value to truncate. |
Returns
| Type | Description |
|---|---|
| System.DateTime | A new System.DateTime missing the minutes, seconds and millseconds components of |