skip navigation
  • Product Bundles

    DevCraft

    All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:

    • AI Coding Assistants
    • Embedded Reporting
    • Document Processing Libraries
    • SSO Account Sign-in

    Web

    Kendo UI UI for Angular UI for Vue UI for jQuery KendoReact UI for Blazor UI for ASP.NET Core UI for ASP.NET MVC UI for ASP.NET AJAX

    Mobile

    UI for .NET MAUI

    Document Management

    Telerik Document Processing

    Desktop

    UI for .NET MAUI UI for WinUI UI for WinForms UI for WPF

    Reporting

    Telerik Reporting Telerik Report Server

    Testing & Mocking

    Test Studio Telerik JustMock

    CMS

    Sitefinity

    AI Productivity Tools

    AI Coding Assistants

    UI/UX Tools

    ThemeBuilder Design System Kit Templates and Building Blocks

    Debugging

    Fiddler Fiddler Everywhere Fiddler Classic Fiddler Everywhere Reporter FiddlerCore

    Free Tools

    KendoReact Free VB.NET to C# Converter Testing Framework
    View all products
  • Overview
  • Demos
    • What's New
    • Roadmap
    • Release History
  • Support and Learning

    • Support and Learning Hub
    • First Steps
    • Docs
    • Demos
    • Virtual Classroom
    • Forums
    • Videos
    • Blogs
    • Accessibility
    • Submit a Ticket

    Productivity and Design Tools

    • Visual Studio Extensions
    • Visual Studio Templates
    • Embedded Reporting
  • Pricing
  • Shopping cart
    • Account Overview
    • Your Licenses
    • Downloads
    • Support Center
    • Forum Profile
    • Payment Methods
    • Edit Profile
    • Log out
  • Login
  • Contact Us
  • Try now

Class GridViewNewRowInfo

Represents a row that enables adding of new rows in RadGridView.

Inheritance
System.Object
GridViewRowInfo
GridViewSystemRowInfo
GridViewNewRowInfo
Inherited Members
GridViewSystemRowInfo.IComparable<GridViewSystemRowInfo>.CompareTo(GridViewSystemRowInfo)
GridViewSystemRowInfo.IsSystem
GridViewSystemRowInfo.Index
GridViewSystemRowInfo.RowPosition
GridViewSystemRowInfo.Parent
GridViewRowInfo.IsAttachedState
GridViewRowInfo.IsModifiedState
GridViewRowInfo.IsCurrentState
GridViewRowInfo.IsSelectedState
GridViewRowInfo.IsExpandedState
GridViewRowInfo.IsVisibleState
GridViewRowInfo.AllowResizeState
GridViewRowInfo.SuspendNotificationsState
GridViewRowInfo.IsInitializedState
GridViewRowInfo.LastRowInfoState
GridViewRowInfo.state
GridViewRowInfo.SetParent(GridViewRowInfo)
GridViewRowInfo.GetActualHeight(IGridView)
GridViewRowInfo.InvalidateRow()
GridViewRowInfo.EnsureVisible()
GridViewRowInfo.EnsureVisible(Boolean)
GridViewRowInfo.Delete()
GridViewRowInfo.GetErrorText(String)
GridViewRowInfo.HasChildRows()
GridViewRowInfo.SuspendPropertyNotifications()
GridViewRowInfo.ResumePropertyNotifications()
GridViewRowInfo.FindParent<T>()
GridViewRowInfo.IDataItem.get_Item(Int32)
GridViewRowInfo.IDataItem.set_Item(Int32, Object)
GridViewRowInfo.IDataItem.get_Item(String)
GridViewRowInfo.IDataItem.set_Item(String, Object)
GridViewRowInfo.IDataItem.IndexOf(String)
GridViewRowInfo.Dispose()
GridViewRowInfo.DispatchEvent(KnownEvents, GridEventType, GridEventDispatchMode, Object, Object[])
GridViewRowInfo.GetEventInfo(GridPropertyChangedEventArgs, GridEventDispatchMode)
GridViewRowInfo.OnPropertyChanging(PropertyChangingEventArgsEx)
GridViewRowInfo.ClearCache()
GridViewRowInfo.SetRowStateProperty<T>(String, T, T)
GridViewRowInfo.SetBooleanProperty(String, Int32, Boolean)
GridViewRowInfo.SearchCache
GridViewRowInfo.IsModified
GridViewRowInfo.ErrorText
GridViewRowInfo.Group
GridViewRowInfo.ViewInfo
GridViewRowInfo.ViewTemplate
GridViewRowInfo.Cells
GridViewRowInfo.Tag
GridViewRowInfo.MinHeight
GridViewRowInfo.MaxHeight
GridViewRowInfo.Height
GridViewRowInfo.IsCurrent
GridViewRowInfo.IsSelected
GridViewRowInfo.IsExpanded
GridViewRowInfo.IsVisible
GridViewRowInfo.IsPinned
GridViewRowInfo.PinPosition
GridViewRowInfo.IsEditable
GridViewRowInfo.IsOdd
GridViewRowInfo.AllowResize
GridViewRowInfo.IDataItem.DataBoundItem
GridViewRowInfo.IDataItem.FieldCount
GridViewRowInfo.IDataItem.Item[Int32]
GridViewRowInfo.IDataItem.Item[String]
GridViewRowInfo.HierarchyLevel
GridViewRowInfo.ChildRows
GridViewRowInfo.HasChildViews
GridViewRowInfo.PropertyChanged
GridViewRowInfo.PropertyChanging
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Telerik.WinControls.UI
Assembly: Telerik.WinControls.GridView.dll

Syntax

public class GridViewNewRowInfo : GridViewSystemRowInfo, IDataItem, IHierarchicalRow, INotifyPropertyChanged, INotifyPropertyChangingEx, IDisposable, IComparable<GridViewSystemRowInfo>

Constructors

GridViewNewRowInfo(GridViewInfo)

Initializes a new instance of the GridViewNewRowInfo.

Declaration
public GridViewNewRowInfo(GridViewInfo gridViewInfo)
Parameters
GridViewInfo gridViewInfo

An instance of GridViewInfo which the current row belongs to.

Properties

AllowedStates

Gets the allowed states for this new row, which is limited to only the Current state.

Declaration
public override AllowedGridViewRowInfoStates AllowedStates { get; }
Property Value
AllowedGridViewRowInfoStates

The Current state only.

Overrides
GridViewRowInfo.AllowedStates

DataBoundItem

Gets the data-bound object that populated the row. For new rows, this returns the data-bound item of the bound row if one exists, otherwise returns the base implementation.

Declaration
public override object DataBoundItem { get; }
Property Value
System.Object

The data-bound object associated with this row, or null if no data binding exists.

Overrides
GridViewRowInfo.DataBoundItem

RowElementType

Gets the type of the GridRowElement that represents this row in the user interface.

Declaration
public override Type RowElementType { get; }
Property Value
System.Type

The System.Type of GridNewRowElement.

Overrides
GridViewRowInfo.RowElementType

Methods

CancelAddNewRow()

Cancels the new row addition process and reverts any changes made during the editing session. This method removes any bound row from the data source and resets the new row to its initial state.

Declaration
public void CancelAddNewRow()

CompareToSystemRowInfo(GridViewSystemRowInfo)

Compares this new row with another system row to determine their relative ordering. New rows are positioned after table header rows but before filtering rows.

Declaration
protected override int CompareToSystemRowInfo(GridViewSystemRowInfo row)
Parameters
GridViewSystemRowInfo row

The GridViewSystemRowInfo to compare with.

Returns
System.Int32

A value indicating the relative order: 1 if this row should come after the specified row, -1 if this row should come before the specified row, or 0 if they are equivalent.

Overrides
GridViewSystemRowInfo.CompareToSystemRowInfo(GridViewSystemRowInfo)

EndAddNewRow()

Completes the process of adding a new row to the grid by validating the data, committing changes to the data source, and raising appropriate events.

Declaration
public GridViewRowInfo EndAddNewRow()
Returns
GridViewRowInfo

The GridViewRowInfo that was successfully added to the grid, or null if the operation was canceled or failed.

InitializeNewRow()

Initializes the new row for user input by setting up default values and preparing the row for editing. This method handles both data-bound and virtual scenarios, creates bound rows when necessary, and raises the DefaultValuesNeeded event to allow setting default values.

Declaration
public void InitializeNewRow()

OnBeginEdit()

Called when the edit operation begins on this new row. Initializes the new row for editing by calling InitializeNewRow() to prepare it for user input.

Declaration
protected override bool OnBeginEdit()
Returns
System.Boolean

True if the edit operation was successfully started; otherwise, false.

Overrides
GridViewRowInfo.OnBeginEdit()

OnEndEdit()

Called when the edit operation ends on this new row. Attempts to complete the new row addition by calling EndAddNewRow() to commit the changes to the data source.

Declaration
protected override bool OnEndEdit()
Returns
System.Boolean

True if the new row was successfully added; otherwise, false.

Overrides
GridViewRowInfo.OnEndEdit()

OnPropertyChanged(PropertyChangedEventArgs)

Called when a property value changes on this new row. Handles special logic for current state changes and row position updates, including cleanup of bound rows when the row loses focus.

Declaration
protected override void OnPropertyChanged(PropertyChangedEventArgs e)
Parameters
System.ComponentModel.PropertyChangedEventArgs e

The System.ComponentModel.PropertyChangedEventArgs containing information about the changed property.

Overrides
GridViewRowInfo.OnPropertyChanged(PropertyChangedEventArgs)

Extension Methods

SvgExtentions.Traverse<T>(T, Func<T, IEnumerable<T>>)
SvgExtentions.TraverseDepthFirst<T>(T, Func<T, IEnumerable<T>>)
Getting Started
  • Install Now
  • Demos
  • Step-by-Step Tutorial
  • Sample Applications
  • SDK Samples
  • Visual Studio Extensions
Support Resources
  • Code Library
  • Knowledge Base
  • Videos
Community
  • Forums
  • Blogs
  • Feedback Portal
  • Document Processing Feedback Portal

Copyright © 2018 Progress Software Corporation and/or its subsidiaries or affiliates.
All Rights Reserved.

Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.