Search Results for

    Show / Hide Table of Contents

    Class DateTimeExtensions

    Defines a collection of data validation extensions for objects.

    Inheritance
    System.Object
    DateTimeExtensions
    Namespace: MADE.Data.Validation.Extensions
    Assembly: MADE.Data.Validation.dll
    Syntax
    public static class DateTimeExtensions : object

    Methods

    | Improve this Doc View Source

    IsInRange(DateTime, DateTime, DateTime)

    Determines whether a is within a valid range.

    Declaration
    public static bool IsInRange(this DateTime date, DateTime from, DateTime to)
    Parameters
    Type Name Description
    DateTime date

    The to check.

    DateTime from

    The lower bound of the range.

    DateTime to

    The upper bound of the range.

    Returns
    Type Description
    System.Boolean

    True if the date is within the valid range.

    | Improve this Doc View Source

    IsWeekday(DateTime)

    Determines whether a is a day of the week other than Sunday or Saturday.

    Declaration
    public static bool IsWeekday(this DateTime date)
    Parameters
    Type Name Description
    DateTime date

    The to check.

    Returns
    Type Description
    System.Boolean

    True if the day of week is between Monday and Friday; otherwise, false.

    | Improve this Doc View Source

    IsWeekend(DateTime)

    Determines whether a is a day of the week other than Monday through Friday.

    Declaration
    public static bool IsWeekend(this DateTime date)
    Parameters
    Type Name Description
    DateTime date

    The to check.

    Returns
    Type Description
    System.Boolean

    True if the day of week is Saturday or Sunday; otherwise, false.

    • Improve this Doc
    • View Source
    In This Article
    Back to top Copyright (c) MADE Apps