why are you setting it like if(Button1.Click)
If you want to perform any action, just do it like this..
protected void Button1_Click(object sender, EventArgs e)
{
if (isCheckboxSelected())
{
string.Format(" completion is successful");
}
else
{
string.Format(" completion is not successful please select each check box");
}
}
Button1_Click itself means that you are telling it to do something on the button click event. So no need to add something like Button1.Click
NOTE:
u can use this Button1.Click in those cases when you want the same work to do on the action of some other event, like
protected void Button2_Focus(object sender, EventArgs e)
{
Button1.Click();
}
Now the focus on button2 make it call to the button1 click event routine..