[Expand]General Information
[Expand]WinForms Controls
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Collapse]WPF Controls
  Prerequisites
 [Expand]What's Installed
 [Expand]Common Concepts
 [Expand]MVVM Framework
 [Collapse]Controls and Libraries
   Reporting
  [Collapse]Data Grid
   [Expand]Getting Started
   [Expand]Implementation Details
   [Expand]Views
   [Expand]Grid View Data Layout
   [Expand]Binding to Data
   [Expand]Master-Detail Data Representation
   [Expand]Data Editing and Validation
   [Expand]Grouping
   [Expand]Selection
   [Expand]Filtering and Searching
   [Expand]Sorting
   [Expand]Data Summaries
   [Expand]Paging and Scrolling
   [Expand]Focus and Navigation
   [Expand]Conditional Formatting
   [Expand]Drag-and-Drop
   [Expand]Appearance Customization
   [Expand]MVVM Enhancements
   [Expand]Printing and Exporting
   [Expand]End-User Interaction
   [Expand]Miscellaneous
   [Expand]Performance Improvement
   [Expand]Design-Time Features
   [Expand]Visual Elements
   [Expand]End-User Capabilities
   [Collapse]Examples
    [Collapse]Binding to Data
      How to: Automatically Create Grid Columns
      How to: Bind a Grid to Data (eXpress Persistent Objects)
      How to: Bind a Grid to an MS Access Database
      How to: Bind a Grid to an XML File
      How to: Bind a Grid to an ICollectionView
      How to: Bind the GridControl to XPO
      How to: Apply Data Annotations
      How to: Post Changes to SQL Database
      How to: Display Unbound Data
      How to: Create a Master-Detail Grid
      How to: Bind Card Headers to Data
      How to: Customize Automatically Generated Columns
      How to: Bind the Grid to Columns and Summaries Specified in ViewModel
      How to: Create a Banded View
      How to: Display Data Which is Being Updated on Another Thread
      How to: Use DXGrid in Server Mode with Entity Framework 4.0+
      How to: Activate the Instant Feedback Mode for the Grid Bound to the Entity Framework 4.0 Classes
      How to: Implement the Instant Feedback Mode (XPO)
      How to: Parallelize Data-Intensive Operations On In-Memory Data in Instant Feedback UI Mode
      How to: Speed Up Performance When Using WCF Data Services (OData) in Instant Feedback Mode
    [Expand]Master-Detail
    [Expand]Hierarchical Data Presentation
    [Expand]Sorting, Grouping and Filtering
    [Expand]Calculating Summaries
    [Expand]Data Editing and Validation
    [Expand]Focus and Navigation
    [Expand]Drag-and-Drop
    [Expand]Styles and Templates
    [Expand]End-User Interaction
    [Expand]Miscellaneous
  [Expand]Ribbon, Bars and Menu
  [Expand]Charts Suite
  [Expand]Pivot Grid
  [Expand]Scheduler
  [Expand]Spreadsheet
  [Expand]Rich Text Editor
  [Expand]Tree List
  [Expand]Gauge Controls
  [Expand]Map Control
  [Expand]Layout Management
  [Expand]Windows Modern UI
  [Expand]Printing-Exporting
  [Expand]Data Editors
  [Expand]Navigation Controls
  [Expand]Spell Checker
  [Expand]Property Grid
  [Expand]PDF Viewer
  [Expand]TreeMap Control
  [Expand]Diagram Control
  [Expand]Windows and Utility Controls
   Dialogs, Notifications and Panels
  [Expand]Scheduler (legacy)
 [Expand]Scaffolding Wizard
 [Expand]Localization
  Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Reporting
[Expand]Report and Dashboard Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

How to: Bind the GridControl to XPO

Show Me

A complete sample project is available in the DevExpress Code Examples database at http://www.devexpress.com/example=E3283.

This example shows how to display data from the "Products" database via DevExpress ORM Tool (XPO).

1. Create a new persistent class representing a data object (ProductDataObject). For information on how to create a persistent class, see Tutorial 1 - Your First Data-Aware Application with XPO.

2. Define a database to store data. For details, see Tutorial 4 - A Windows Forms Application for Data Editing.

3. Bind the grid control to a new XPCollection object.

Is this topic helpful?​​​​​​​