menu

WinForms

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class DateSelections - WindowsForms API Reference | Syncfusion

    Show / Hide Table of Contents

    Class DateSelections

    Holds a collection of DateTime objects.

    Inheritance
    System.Object
    System.Collections.ArrayList
    DateSelections
    Implements
    System.Collections.IList
    System.Collections.ICollection
    System.Collections.IEnumerable
    System.ICloneable
    Inherited Members
    System.Collections.ArrayList.Adapter(System.Collections.IList)
    System.Collections.ArrayList.BinarySearch(System.Int32, System.Int32, System.Object, System.Collections.IComparer)
    System.Collections.ArrayList.BinarySearch(System.Object)
    System.Collections.ArrayList.BinarySearch(System.Object, System.Collections.IComparer)
    System.Collections.ArrayList.Capacity
    System.Collections.ArrayList.Clone()
    System.Collections.ArrayList.Contains(System.Object)
    System.Collections.ArrayList.CopyTo(System.Array)
    System.Collections.ArrayList.CopyTo(System.Array, System.Int32)
    System.Collections.ArrayList.CopyTo(System.Int32, System.Array, System.Int32, System.Int32)
    System.Collections.ArrayList.Count
    System.Collections.ArrayList.FixedSize(System.Collections.ArrayList)
    System.Collections.ArrayList.FixedSize(System.Collections.IList)
    System.Collections.ArrayList.GetEnumerator()
    System.Collections.ArrayList.GetEnumerator(System.Int32, System.Int32)
    System.Collections.ArrayList.GetRange(System.Int32, System.Int32)
    System.Collections.ArrayList.IndexOf(System.Object)
    System.Collections.ArrayList.IndexOf(System.Object, System.Int32)
    System.Collections.ArrayList.IndexOf(System.Object, System.Int32, System.Int32)
    System.Collections.ArrayList.Insert(System.Int32, System.Object)
    System.Collections.ArrayList.InsertRange(System.Int32, System.Collections.ICollection)
    System.Collections.ArrayList.IsFixedSize
    System.Collections.ArrayList.IsReadOnly
    System.Collections.ArrayList.IsSynchronized
    System.Collections.ArrayList.LastIndexOf(System.Object)
    System.Collections.ArrayList.LastIndexOf(System.Object, System.Int32)
    System.Collections.ArrayList.LastIndexOf(System.Object, System.Int32, System.Int32)
    System.Collections.ArrayList.ReadOnly(System.Collections.ArrayList)
    System.Collections.ArrayList.ReadOnly(System.Collections.IList)
    System.Collections.ArrayList.Remove(System.Object)
    System.Collections.ArrayList.Repeat(System.Object, System.Int32)
    System.Collections.ArrayList.Reverse()
    System.Collections.ArrayList.Reverse(System.Int32, System.Int32)
    System.Collections.ArrayList.SetRange(System.Int32, System.Collections.ICollection)
    System.Collections.ArrayList.Sort()
    System.Collections.ArrayList.Sort(System.Collections.IComparer)
    System.Collections.ArrayList.Sort(System.Int32, System.Int32, System.Collections.IComparer)
    System.Collections.ArrayList.Synchronized(System.Collections.ArrayList)
    System.Collections.ArrayList.Synchronized(System.Collections.IList)
    System.Collections.ArrayList.SyncRoot
    System.Collections.ArrayList.ToArray()
    System.Collections.ArrayList.ToArray(System.Type)
    System.Collections.ArrayList.TrimToSize()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: Syncfusion.Windows.Forms.Schedule
    Assembly: Syncfusion.Schedule.Windows.dll
    Syntax
    public class DateSelections : ArrayList, IList, ICollection, IEnumerable, ICloneable
    Remarks

    This class hold the dates that are the currently selected dates for the ScheduleControl. As your user clicks and drags in the NavigationControl panel, an instance of this class holds the currently selected dates.

    Constructors

    DateSelections()

    Initializes a new instance of the DateSelections class.

    Declaration
    public DateSelections()

    Properties

    Item[Int32]

    Gets or sets the DateTime value at position i in this collection.

    Declaration
    public DateTime this[int i] { get; set; }
    Parameters
    Type Name Description
    System.Int32 i

    The position used to retrieve the desired DateTime value.

    Property Value
    Type
    System.DateTime

    Methods

    Add(Object)

    Adds an object to the collection conditionally.

    Declaration
    public void Add(object t)
    Parameters
    Type Name Description
    System.Object t

    The object to be added.

    Remarks

    This collection will only hold unique occurrences of each date. This Add method hides the ArrayList.Add method to make sure no duplicates are added. It also raises the SelectionsChanged event.

    AddRange(ICollection)

    Adds a collection of objects to this collection.

    Declaration
    public void AddRange(ICollection timeArray)
    Parameters
    Type Name Description
    System.Collections.ICollection timeArray

    The collection to be added.

    Remarks

    This method raises the SelectionsChanged event.

    BeginUpdate()

    Suspends the collection from raising the SelectionsChanged event.

    Declaration
    public void BeginUpdate()
    Remarks

    You can call this method before making a series of additions/removals from this collection. This will prevent any listener to SelectionsChanged from seeing these changes. You can then use EndUpdate to resume the SelectionsChanged event being raised.

    Clear()

    Clears this collection.

    Declaration
    public void Clear()
    Remarks

    This method raises the SelectionsChanged event.

    EndUpdate()

    Resumes the raising of the SelectionsChanged event.

    Declaration
    public void EndUpdate()

    EndUpdate(Boolean)

    Resumes the raising of the SelectionsChanged event.

    Declaration
    public void EndUpdate(bool ignoreSelectionsChanged)
    Parameters
    Type Name Description
    System.Boolean ignoreSelectionsChanged

    False if you want the SelectionsChanged event to be raised to alert event listeners to the current state of the collection.

    OnSelectionsChanged()

    Raises the SelectionsChanged event.

    Declaration
    public virtual void OnSelectionsChanged()

    Remove(DateTime)

    Removes a DateTime from this collection.

    Declaration
    public void Remove(DateTime dt)
    Parameters
    Type Name Description
    System.DateTime dt

    The date to be removed.

    Remarks

    This method raises the SelectionsChanged event.

    RemoveAt(Int32)

    Removes a item from this collection at the index passed inAddControlToNavigationPanel.

    Declaration
    public void RemoveAt(int index)
    Parameters
    Type Name Description
    System.Int32 index

    The index of the item to be removed.

    Remarks

    This method raises the SelectionsChanged event.

    RemoveRange(Int32, Int32)

    Removes a range of items from this collection.

    Declaration
    public void RemoveRange(int index, int count)
    Parameters
    Type Name Description
    System.Int32 index

    The index of the first item to be removed.

    System.Int32 count

    The number of items to be removed.

    Remarks

    This method raises the SelectionsChanged event.

    Events

    SelectionsChanged

    Occurs when items in the collection are added or removed.

    Declaration
    public event SelectionsChangedEventHandler SelectionsChanged
    Event Type
    Type
    SelectionsChangedEventHandler

    Implements

    System.Collections.IList
    System.Collections.ICollection
    System.Collections.IEnumerable
    System.ICloneable

    Extension Methods

    EnumerableExtensions.GetElementType(IEnumerable)
    EnumerableExtensions.GetItemPropertyInfo(IEnumerable)
    FunctionalExtensions.ForEach<T>(IEnumerable, Action<T>)
    FunctionalExtensions.ToList<T>(IEnumerable)
    FunctionalExtensions.MoveTo(IList, Int32, Int32)
    QueryableExtensions.OfQueryable(IEnumerable)
    QueryableExtensions.OfQueryable(IEnumerable, Type)
    QueryableExtensions.GroupByMany<TElement>(IEnumerable, Type, List<Func<TElement, Object>>)
    QueryableExtensions.GroupByMany(IEnumerable, Type, Func<String, Expression>, String[])
    QueryableExtensions.GroupByMany(IEnumerable, Type, List<SortDescriptor>, Dictionary<String, IComparer<Object>>, Func<String, Expression>, String[])
    QueryableExtensions.GroupByMany(IEnumerable, Type, List<SortDescriptor>, Func<String, Expression>, String[])
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved