expressappframework-devexpress-dot-expressapp-dot-xpo-dot-xpobjectspaceprovider-7aee9e03.md
Instantiates an Object Space.
Namespace : DevExpress.ExpressApp.Xpo
Assembly : DevExpress.ExpressApp.Xpo.v25.2.dll
NuGet Package : DevExpress.ExpressApp.Xpo
public IObjectSpace CreateObjectSpace()
Public Function CreateObjectSpace As IObjectSpace
| Type | Description |
|---|---|
| IObjectSpace |
An IObjectSpace object that is the instantiated Object Space.
|
If you implement a custom SecuredObjectSpaceProvider with the CreateObjectSpace method overridden, make sure this method returns an object of the SecuredXPObjectSpace type instead of XPObjectSpace.
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the CreateObjectSpace() 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.
using (XPObjectSpaceProvider objectSpaceProvider = CreateObjectSpaceProvider()) {
IObjectSpace objectSpace = objectSpaceProvider.CreateObjectSpace();
ReportDataV2 reportData = objectSpace.FindObject<ReportDataV2>(new BinaryOperator("DisplayName", "Employees Report"));
See Also