public RoutedEvents6Page() { this.InitializeComponent(); vm = new TapTextBlockPageViewModel(); this.DataContext = vm; this.AddHandler(UIElement.TappedEvent, new TappedEventHandler(OnPageTapped), true); // true to receive TextBlock Handled events, false to not receive them }
public TapTextBlockPage() { this.InitializeComponent(); vm = new TapTextBlockPageViewModel(); this.DataContext = vm; }