Reputation: 39
I am working currently on my clock application in C# in Visual Studio 2015.
private void Form1_Load(object sender, EventArgs e)
{
t.Interval = 1000;
t.Tick() += new EventHandler(this.t_Tick);
t.Start();
}
and this part t.Tick() += new EventHandler(this.t_Tick);
has some kind of problem shown here:
I would appreciate it if you provided me with a full explanation of this issue.
ERROR LIST:
1) Error CS0079 The event 'Timer.Tick' can only appear on the left hand side of += or -=
2) Error CS7036 There is no argument given that corresponds to the required formal parameter 'sender' of 'EventHandler'
Upvotes: 0
Views: 131