XPClassInfo.CreateNewObject(Session) Method
Creates a new persistent object.
Namespace: DevExpress.Xpo.Metadata
Assembly: DevExpress.Xpo.v24.1.dll
NuGet Packages: DevExpress.Win.PivotGrid, DevExpress.Win.TreeMap, DevExpress.Xpo
NuGet Package: DevExpress.Xpo
Declaration
Parameters
Name | Type | Description |
---|---|---|
session | Session | A Session object which represents the session. This property is assigned to the object’s PersistentBase.Session property. |
Returns
Type | Description |
---|---|
Object | An object which is the newly created persistent object. |
Remarks
After the CreateNewObject method creates an object, it is marked as “new”, to be inserted into the database later and its PersistentBase.AfterConstruction method is invoked.
Related GitHub Examples
The following code snippets (auto-collected from DevExpress Examples) contain references to the CreateNewObject(Session) method.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.