Main Content

Validate and Activate Variant Configurations

This example shows how to validate and activate a variant configuration programmatically.

To activate a variant configuration from Variant Manager, see Create and Activate Variant Configurations.

Open the model slexVariantManagement.

open_system("slexVariantManagement");

Activate and validate the model using the variant control variables and their values currently present in the base workspace or data dictionary used by the model.

Simulink.VariantManager.activateModel("slexVariantManagement");

Activate and validate the model using the variant configuration LinInterExpNoNoise.

Simulink.VariantManager.activateModel ...
("slexVariantManagement",Configuration="LinInterExpNoNoise");