Microsoft Silverlight will reach end of support after October 2021. Learn more.
Adds a new item to the underlying collection.
Assembly: System.Windows.Data (in System.Windows.Data.dll)
'Declaration Public Function AddNew As Object
public Object AddNew()
The new item that is being added.
After calling AddNew and changing the new item as needed, you should call either CommitNew or CancelNew to complete the transaction. Calling AddNew before a previous add or edit transaction has been committed or canceled will cause the previous transaction to be committed. The new item will always appear in the collection view. Any filtering, sorting, or grouping that is applied to the view is applied to the new item when CommitNew is called.
Use the CanAddNew property to test whether a new item can be added before you call AddNew.
Supported in: 5, 4, 3
For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.