Q:

An error No overload for 'timer_Tick' matches delegate 'System. EventHandler'

I am not sure what is wrong with my code can someone help fix the error?  The error is in the timer. Tick() line.  It's supposed to make a stopwatch. 
namespace App3
{
    public sealed partial class MainPage : Page
    {
        public MainPage()
        {                
            this. InitializeComponent();
        }
        private int myCount;

        protected override void OnNavigatedTo(NavigationEventArgs e)
        {
            DispatcherTimer timer = new DispatcherTimer();
            timer. Tick += new EventHandler<object>(timer_Tick);
            timer. Interval = TimeSpan. FromSeconds(5);
            timer. Start();    
        }

        protected override void OnNavigatedFrom(NavigationEventArgs e)
        {
            base. OnNavigatedFrom(e);
        }

        private void timer_Tick(object sender, EventArgs e)
        {
            myCount++;
            Label. Text = myCount. ToString();
        }
    }

A:

DispatcherTimer. Tick is an EventHandler, not an EventHandler<object>. 
You need to change your code to specify this correctly:
 timer. Tick += new EventHandler(timer_Tick);

Note that this can also be written in short form, which is typically safer:
timer. Tick += timer_Tick;

A:

Delegate types are not required when attaching events, the compiler can figure it out for you.  Try this instead:
timer. Tick += timer_Tick;

As for why you get the error currently, the EventHandler delegate is declared like this:
public delegate void EventHandler<TEventArgs>(
    Object sender,
    TEventArgs e
)

This means the type you put in the brackets represents the second argument in the function.  
So when you type EventHandler<object>, the compiler looks for a function like timer_Tick(Object sender, object e) which it does not find, hence the error.  To use the full delegate type, it would have to be EventHandler<EventArgs>

