I have created a TextBox
dynamically and attached a Tap event handler to it using:
control.Tap += new EventHandler<System.Windows.Input.GestureEventArgs>(OnClick1);
It works fine. But, now I want to change the event handler to point to some different method. I tried:
control.Tap += new EventHandler<System.Windows.Input.GestureEventArgs>(OnClick2);
但是,它仍然指向第一事件手。 i.e. OnClick1
。 我可以做些什么来说明