Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

SpreadsheetControlOptions.DataSourceOptions Property

Allows you to specify whether to prohibit the ObjectDataSource data retrieval, prompt the user or silently load the data.

Namespace: DevExpress.XtraSpreadsheet

Assembly: DevExpress.XtraSpreadsheet.v24.2.dll

NuGet Package: DevExpress.Win.Spreadsheet

#Declaration

public DataSourceOptionsContainer DataSourceOptions { get; }

#Property Value

Type Description
DataSourceOptionsContainer

An object that contains data source options.

#Property Paths

You can access this nested property as listed below:

Object Type Path to DataSourceOptions
SpreadsheetControl
.Options .DataSourceOptions

#Remarks

If the DataSourceOptions specifies to prompt the user, the ObjectDataSourceValidationService service is called for validation. You can implement your own service and provide a custom validation instead of displaying the default warning dialog.

#Example

spreadsheetControl1.Options.DataSourceOptions.ObjectDataSourceLoadingBehavior = DevExpress.DataAccess.DocumentLoadingBehavior.Prompt;
See Also