Scheduler for WPF and Silverlight | ComponentOne
C1.Silverlight.Schedule Namespace / VisualInterval Class / ContainsTime Method
A checked DateTime.

In This Topic
    ContainsTime Method (VisualInterval)
    In This Topic
    Gets a value indicating whether the specified DateTime belongs to the time range represented by the VisualInterval.
    Syntax
    'Declaration
     
    
    Public Function ContainsTime( _
       ByVal time As Date _
    ) As Boolean
    public bool ContainsTime( 
       DateTime time
    )

    Parameters

    time
    A checked DateTime.

    Return Value

    This method returns true if the specified DateTime belongs to the time range represented by the VisualInterval; otherwise, false.
    Remarks
    A DateTime is considered as belonging to a VisualInterval if the following condition is satisfied:

    StartTime <= DateTime and DateTime > EndTime

    Note that the bottom boundary of the interval is exclusive, that is DateTime = EndTime is considered as not belonging to the interval.

    See Also