Search This Blog

Showing posts with label Java Script function. Show all posts
Showing posts with label Java Script function. Show all posts

Tuesday, April 19, 2011

Call Java Script function on cs page

<script language="javascript" type="text/javascript">
function ConfirmDeletion()
{
return confirm('Are you sure you want to delete this record?');
}
</script>


if (e.Row.RowType == DataControlRowType.DataRow)
        {
            e.Row.Cells[7].Attributes.Add("onclick", "return ConfirmDeletion();");
        }