Q&A #20 – Click vs Tap in Windows Phone Button Control

Q&A #20 – Click vs Tap in Windows Phone Button Control

The Button control in Windows Phone exposes the following 2 events “Click” and “Tap” .

Click vs Tap in Windows Phone Button Control

Click vs Tap in Windows Phone Button Control

Although , you can use either of the event , generally the tap event is designed specially for the touch .

private void button1_Click(object sender, RoutedEventArgs e)
{         

}

private void button1_Tap(object sender, GestureEventArgs e)
{

}

The Click event is mainly used when handling the mouse states and can be used if the same code is used for the Silverlight Desktop App.

Leave a Reply