Skip to main content

IExtractDataSourceWizardCustomization Interface

Provides the capability to customize the Data Source wizard for the Extract Data Source.

Namespace: DevExpress.DashboardWin

Assembly: DevExpress.Dashboard.v22.1.Win.dll

Declaration

public interface IExtractDataSourceWizardCustomization

Remarks

To customize the Data Source wizard pages for the Extract Data Source, create an object that implements the IExtractDataSourceWizardCustomization interface and assign it to the WizardCustomization property.

Example

This example demonstrates how to customize the Data Source Wizard pages and invoke a customized Wizard in the DashboardViewer.

The static EditExtractOptions(DashboardExtractDataSource, EditExtractOptionsContext) method invokes the Data Source Wizard.

To customize the Edit extract page, the application uses the approach described in the following document: How to Customize Views and Presenters Corresponding to Wizard Pages.

![](~/images/how-to-customize -extract-datasource-wizard.png)

View Example: How to Customize the Data Source Wizard and Invoke It in the DashboardViewer

private void btn_RunWizard_Click(object sender, EventArgs e) {
    EditExtractOptionsContext optionsContext = new EditExtractOptionsContext(this.GetActiveLookAndFeel(), this, dashboardViewer1.Dashboard.DataSources);
    optionsContext.WizardCustomization = new CustomExtractDataSourceWizardCustomizationService();
    ExtractDataSourceUIHelper.EditExtractOptions(new DashboardExtractDataSource() { FileName = "test.dat" }, optionsContext);
}

It implements the IExtractDataSourceWizardCustomization interface in a CustomExtractDataSourceWizardCustomizationService class to register a customized page view:

public class CustomExtractDataSourceWizardCustomizationService : IExtractDataSourceWizardCustomization {
    public void CustomizeDataSourceWizard(IWizardCustomization<ExtractDataSourceModel> customization) {
        customization.RegisterPageView<ICreateExtractDataSourcePageView, CustomConfigureExtractDataSourcePageView>();
    }
}

A customized page view is the CustomConfigureExtractDataSourcePageView class that inherits the CreateExtractDataSourcePageView type:

public class CustomConfigureExtractDataSourcePageView : CreateExtractDataSourcePageView {
    public CustomConfigureExtractDataSourcePageView() : base() {                     
        this.checkEditExistingDataSource.Enabled = false;            
    }

    protected override void OnCheckEditExistingDataSourceCheckedChanged(object sender, EventArgs e) {
        base.OnCheckEditExistingDataSourceCheckedChanged(sender, e);
        TextEditFileName.Enabled = false;
    }
}

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the IExtractDataSourceWizardCustomization interface.

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.

See Also