this code will be excuted on first click. So, the onclick attribute for the button will affect only from the second time. So, You add onclick attribute for the Image button on Row data bound event like this..
if(e.Row.RowType == DataControlRowType.DataRow)
{
Image img = (Image)e.Row.FindControl("imgSMS");
img.Attributes.Add("onclick","window.open('Admin/Default.aspx','_blank','toolbar=0,location=0,menubar=0,resizable=0,height=300,width=300');return false");
}
hope it works..