Back to Devexpress

LINQ to SQL

windowsforms-115503-controls-and-libraries-pivot-grid-binding-to-data-data-source-configuration-wizard-linq-to-sql.md

latest1.4 KB
Original Source

LINQ to SQL

  • Dec 23, 2021
  • 2 minutes to read

The Data Source Configuration Wizard allows you to bind the PivotGridControl to an SQL database using LINQ to SQL at design time. This topic shows how to do this.

  1. Click the Data Source Wizard button placed on the PivotGridControl or use the corresponding command in the control’s smart tag.

  2. In the invoked Data Source Configuration Wizard, select LINQ to SQL

  3. The following message will appear.

  4. Make sure that the LINQ to SQL Classes item is selected in the invoked dialog. Then, specify the required name and click Add.

  5. After creating LINQ to SQL classes, click the Data Source Wizard button again.

  6. In the invoked Data Source Configuration Wizard, select the created data model.

  7. On the next page, select the required binding method.

  8. On the final page, you can specify the table.

  9. The following code will be generated by the Data Source Configuration Wizard.

See Also

Server Mode with LINQ to SQL

Server Mode