I have Page on silverlight which has a textbox, I need to handle the GotFocus event on the textbox, but the problem is that this particular event spreads out over the all object graph, so when any other object throws a GotFocus event the textbox’s GotFocus that I want to handler is raised, too
Share
GotFocus is a routed event, this means it will work its way up the Visual Tree until something marks it as handled.
You are describing that which is expected from the event type.
If there is some undesirable side-effect from the event continuing to ‘bubble up’. You can mark the event as handled to stop it.
You can also check the OriginalSource property of the event to see if the event originated from your TextBox.