New to Telerik UI for WinFormsStart a free 30-day trial

Definition

Namespace:Telerik.WinControls.UI

Assembly:Telerik.WinControls.UI.dll

Syntax:

C#
public class DateTimeCollection : IList, ICollection, IEnumerable, ICloneable

Inheritance: objectDateTimeCollection

Implements: ICloneableICollectionIEnumerableIList

Constructors

C#
public DateTimeCollection()
C#
public DateTimeCollection(RadCalendar calendar)
Parameters:calendarRadCalendar

Properties

Gets the total number of DateTime objects in the collection.

C#
public virtual int Count { get; }

Implements: ICollection.Count

Gets or sets the DateTime at the specified indexed location in the collection.

C#
public virtual DateTime this[int index] { get; set; }
Parameters:indexint

The indexed location of the DateTime in the collection.

Property Value:

The DateTime at the specified indexed location in the collection.

Methods

Adds a previously created DateTime object to the end of the DateTimeCollection.

C#
public virtual DateTime Add(DateTime date)
Parameters:dateDateTime

The DateTime object to add to the collection.

Returns:

DateTime

The zero-based index value of the DateTime object added to the DateTimeCollection.

Adds an array of previously created DateTime objects to the collection.

C#
public virtual void AddRange(DateTime[] inputItems)
Parameters:inputItemsDateTime[]

An array of DateTime objects representing the dates to add to the collection.

C#
public void BeginUpdate()

CanAdd method verify whether the date can be add to the collection.

C#
public virtual bool CanAdd(DateTime date)
Parameters:dateDateTime

The DateTime object to insert into the collection.

Returns:

bool

Removes all DateTime objects from the collection.

C#
public void Clear()

Creates a new DateTimeCollection object that is a copy of the current instance.

C#
public virtual DateTimeCollection Clone()
Returns:

DateTimeCollection

A new DateTimeCollection object that is a copy of this instance.

Determines whether the specified DateTime object is a member of the collection.

C#
public virtual bool Contains(DateTime value)
Parameters:valueDateTime

The DateTime to locate in the collection.

Returns:

bool

true if the DateTime is a member of the collection; otherwise, false.

C#
public void EndUpdate()

Returns an enumerator that can be used to iterate through the DateTime collection.

C#
public virtual IEnumerator<DateTime> GetEnumerator()
Returns:

IEnumerator<DateTime>

An IEnumerator that represents the DateTime collection.

Returns the index of the specified DateTime object in the collection.

C#
public virtual int IndexOf(DateTime date)
Parameters:dateDateTime

The DateTime object to locate in the collection.

Returns:

int

The zero-based index of the item found in the DateTimeCollection; otherwise, -1.

Inserts an existing DateTime object into the DateTimeCollection at the specified location.

C#
public virtual void Insert(int index, DateTime date)
Parameters:indexint

The indexed location within the collection to insert the DateTime object.

dateDateTime

The DateTime object to insert into the collection.

Removes the specified DateTime object from the DateTimeCollection.

C#
public virtual void Remove(DateTime date)
Parameters:dateDateTime

The DateTime object to remove.

C#
public virtual void RemoveRange(DateTime[] dates)
Parameters:datesDateTime[]

Removes a range of DateTime elements from the DateTimeCollection.

C#
public virtual void RemoveRange(int index, int count)
Parameters:indexint

The zero-based starting index of the range of elements to remove.

countint

The number of elements to remove.

Copies the elements of the DateTime collection to a new DateTime array.

C#
public virtual DateTime[] ToArray()
Returns:

DateTime[]

A DateTime array

C#
protected void UpdateOwnerVisuals()