RefreshProperties Wyliczenie

Definicja

Definiuje identyfikatory wskazujące typ odświeżania okno Właściwości.

public enum class RefreshProperties
public enum RefreshProperties
type RefreshProperties = 
Public Enum RefreshProperties
Dziedziczenie
RefreshProperties

Pola

All 1

Właściwości powinny zostać ponownie wyczekiwane, a widok powinien zostać odświeżony.

None 0

Nie trzeba odświeżać.

Repaint 2

Widok powinien zostać odświeżony.

Przykłady

W poniższym przykładzie RefreshPropertiesAttribute użyto klasy do określenia trybu odświeżania DataSource właściwości. Aby uzyskać pełną listę kodu, zobacz How to: Apply Attributes in Windows Forms Controls (Instrukcje: stosowanie atrybutów w kontrolkach Windows Forms).

[Category("Data")]
[Description("Indicates the source of data for the control.")]
[RefreshProperties(RefreshProperties.Repaint)]
[AttributeProvider(typeof(IListSource))]
public object DataSource
{
    get
    {
        return this.dataGridView1.DataSource;
    }

    set
    {
        this.dataGridView1.DataSource = value;
    }
}
<Category("Data"), _
Description("Indicates the source of data for the control."), _
RefreshProperties(RefreshProperties.Repaint), _
AttributeProvider(GetType(IListSource))> _
Public Property DataSource() As Object
    Get
        Return Me.dataGridView1.DataSource
    End Get

    Set(ByVal value As Object)
        Me.dataGridView1.DataSource = value
    End Set
End Property

Uwagi

RefreshPropertiesdefiniuje identyfikatory typów metod odświeżania, które mogą być używane podczas odświeżania widoku okno Właściwości.

Dotyczy

Zobacz też