IRangeValueProvider.Value Proprietà

Definizione

Ottiene il valore del controllo.

public:
 property double Value { double get(); };
public double Value { get; }
member this.Value : double
Public ReadOnly Property Value As Double

Valore della proprietà

Double

Valore del controllo o null (Nothing in Visual Basic) se il controllo non supporta Value.

Esempio

Nell'esempio seguente viene illustrata un'implementazione di questo metodo per un controllo personalizzato. Ai fini di questo esempio, il controllo personalizzato visualizza il valore tramite l'impostazione alfa del colore di base.

/// <summary>
/// Specifies the current value of the control.
/// </summary>
/// <remarks>
/// For the purposes of this sample, the custom control displays 
/// its value through the alpha setting of the base color.
/// </remarks>
public double Value
{
    get 
    {
        return customControl.colorAlpha; 
    }
}
''' <summary>
''' Specifies the current value of the control.
''' </summary>
''' <remarks>
''' For the purposes of this sample, the custom control displays 
''' its value through the alpha setting of the base color.
''' </remarks>
Public ReadOnly Property Value() As Double Implements IRangeValueProvider.Value
    Get
        Return customControl.colorAlpha
    End Get
End Property

Si applica a

Vedi anche