Spread Windows Forms 18
FarPoint.Win Assembly / FarPoint.Win Namespace / ElementWindowless Class / CanFocus Property
Example


In This Topic
    CanFocus Property (ElementWindowless)
    In This Topic
    Gets or sets whether the element can receive focus.
    Syntax
    'Declaration
     
    
    Public Overridable Property CanFocus As Boolean
    'Usage
     
    
    Dim instance As ElementWindowless
    Dim value As Boolean
     
    instance.CanFocus = value
     
    value = instance.CanFocus
    public virtual bool CanFocus {get; set;}
    Example
    private void button1_Click(object sender, System.EventArgs e)
    {
    element.Visible = true;
    element.Enabled = false;
    element.Selectable = false;
    element.CanFocus = false;
    }
    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
    element.Visible = True
    element.Enabled = False
    element.Selectable = False
    element.CanFocus = False
    End Sub
    See Also