i am adding more than one link button during runtime but they all have the same name. so how can i differentiate between their events because i want everyone to have a different parameter or variable. this is my code:
while(drr.Read())
{
LinkButton lb = new LinkButton();
lb.Click += new EventHandler(lb_Click);
lb.Text = drr[2].ToString();
PlaceHolderQuestions.Controls.Add(lb);
}
and outside that there is the event handler:
void lb_Click(object sender, EventArgs e)
{
DownloadFile();
}
how can i know which button is pressed?