Retrieves and sets the override value of a setting. Namespace: Microsoft.ComponentStudio.ComponentPlatformInterface
Assembly: Microsoft.ComponentStudio.ComponentPlatformInterface (in microsoft.componentstudio.componentplatforminterface.dll)


Visual Basic
Dim answerFileSettingOverride1 As AnswerFileSettingOverride

Dim returnValue As String
returnValue = answerFileSettingOverride1.Value

Dim sampleValue As String
answerFileSettingOverride1.Value = sampleValue


Visual Basic
Public Shadows Property Value() As String
public new string Value {get; set;}
property String^ Value {
		String^ get();
		void set(String^ value);
public System.String get_Value();
public void set_Value(System.String);
public hide function get Value() : String;
public hide function set Value(String);

Property Value

The root object of the answer file setting override.


The following table shows the exception types for this property.

Exception Types



Thrown if the value is set to null, and the CanBeNull property of the corresponding Definition object is false.


Thrown if one of the following is true:

  • The setting is a complex type.

  • The parent of the setting is a list type, and the setting is a key of the list, and the value is null. (The key of a list type cannot be null.)

  • The parent of the setting is a list type, and the setting is a key of the list, and a key of the same value already exists. (A list type cannot have duplicate keys.)

  • The value is invalid.


Thrown if the setting is an array of strings. In this case use StringArrayValue instead.

Use this property to set the override value of a simple type setting. For a setting of complex types, you must navigate to the instances of AnswerFileSettingOverride that represent each leaf of the complex type and set the override value on the leaf instance.

If the setting type is an array of strings (the IsArrayType property returns true and DataType is typeof(String) for the corresponding Definition object), then you should not use this property to set the override. Instead, you should use StringArrayValue.

A null value is allowed if the CanBeNull property of the corresponding Definition object is true. In this case, an empty string will be written to the answer file for this setting, and the xsi:nil attribute will be set to true. To completely remove the override from answer file, call Remove.

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.


Development Platforms

Windows XP Home Edition, Windows XP Professional, Windows Server 2003, Windows Vista, and Windows 2000

Target Platforms

See Also