Harness proD API Help
EPLAN.Harness.API.DataStructures.Tasks Namespace / TaskConfiguration Class / TaskConfiguration Constructor
Name of the configuration (must be unique).
Active task types for this configuration.
Example
In This Topic
    TaskConfiguration Constructor
    In This Topic
    Creates new task configuration.
    Syntax
    public TaskConfiguration( 
       string name,
       ApiTaskType types
    )

    Parameters

    name
    Name of the configuration (must be unique).
    types
    Active task types for this configuration.
    Exceptions
    ExceptionDescription
    Argument is null.
    Argument is invalid. The exception is thrown when a wrong argument is passed to the method or the setter of property.
    Remarks
    The configuration is not yet added to the project.
    Example
    This example show how to create configuration with a lot of types.
    // All types of tasks are required except of one (surface protection check).
    // Instead of listing all required types use AllTaskTypes static property and remove the one type which is not required.
    ApiTaskType types = TaskConfiguration.AllTaskTypes;
    types  &= ~ApiTaskType.SurfaceProtectionCheck;
    
    // Create the task configuration.
    TaskConfiguration config = new TaskConfiguration("APIConfig", types);
    See Also