-
David,
I have attached a solution that illustrates how to overcome this issue. Please review it. This should be helpful.
Thank you, Marina
It is helpfull, thank you.
Hello,
We have researched this issue. The GotFocus and LostFocus are standard events. We do not raise them ourselves. Our TextEdit wraps the TextBox. When you use keys, you focus the TextEdit, but then focus changes from the TextEdit to the internal TextBox. This is the reason why the GotFocus event if fired twice. You should listen to this event only for the internal editor. In some cases, it may be necessary to listen to this event for both elements. This is the reason why we do not plan to change this behavior on our side. I hope my solution is applicable.
Thank you, Marina
-
It appears after 6 years it is still ok to fire LostFocus events when a control hasn't lost focus.Hi Craig,
As Marina correctly mentioned, this behavior occurs because our editors display their values using an addition control. The control type may depend on the used editor, but text editors mostly use TextBox. When an internal editor is focused, the editor loses the focus, and this is the only reason why the standard LostFocus event is raised.
If you are looking for an event that allows you to check if the focus is within your text editor, I suggest you handle the IsKeyboardFocusWithinChanged event instead. Please try this approach to see if it allows you to achieve your goal.