i´ve tryed to manage the event got y lost focus with a textbox and everything goes rigth, when i try with a ultraTextEditor this takes a unusual behavior (and theoretically its the same code, i just changed the name of the textbox). In fact with addHandler a cant see infragistics control in the intellisence. Could it be posible that infragistics does not support addhandler or em i have concepts problem?
Public Class Form1 Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load CheckBox1.TabIndex = 0 UltraTextEditor1.TabIndex = 1 Label1.TabIndex = 2 End Sub Private Sub a(ByVal s As Object, ByVal e As EventArgs) Handles UltraTextEditor1.GotFocus Label1.Text = "tiene foco" End Sub Private Sub b(ByVal s As Object, ByVal e As EventArgs) Handles UltraTextEditor1.LostFocus Label1.Text = "pierde foco" End Sub End Class
Public Class Form2 Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load CheckBox1.TabIndex = 0 TextBox1.TabIndex = 1 Label1.TabIndex = 2 End Sub Private Sub a(ByVal s As Object, ByVal e As EventArgs) Handles TextBox1.GotFocus Label1.Text = "tiene foco" End Sub Private Sub b(ByVal s As Object, ByVal e As EventArgs) Handles TextBox1.LostFocus Label1.Text = "pierde foco" End Sub End Class
can anyone help me to understand whats goin on?
you are rigth, i tryed with enter and leave and it works as spected.
im so thank you very much, it really help. i tryed with a lot of other events and i didnt work
You should not use GotFocus and LostFocus events. These event are directly tied to Windows messages and even Microsoft's documentation advises against using them. You should probably use the Enter and Leave events, instead.