Hi Friends,
Please help me out on this.
Code :
function delete1()
{
var i=confirm("do you want to delete current row");
alert(i);
if (i==true)
{
hidden1.value=i ; //hidden1 is hidden field;
}
}
I am calling this method in in button click source code as
onclientclick=" delete1();"
in .cs file i am using the following code in button click.
if (hidden1.value= =true)
{
dw1.deleterow(0 );
}
else
{
label1.text="so rry";
}
Its working with out any error. But while deleting even though i pressed cacel
it is deleting row.
I think its the problem with catching the boolean value.Whether it is true or false in code behind.
Thanks in adance,
gmail
Please help me out on this.
Code :
function delete1()
{
var i=confirm("do you want to delete current row");
alert(i);
if (i==true)
{
hidden1.value=i ; //hidden1 is hidden field;
}
}
I am calling this method in in button click source code as
onclientclick=" delete1();"
in .cs file i am using the following code in button click.
if (hidden1.value= =true)
{
dw1.deleterow(0 );
}
else
{
label1.text="so rry";
}
Its working with out any error. But while deleting even though i pressed cacel
it is deleting row.
I think its the problem with catching the boolean value.Whether it is true or false in code behind.
Thanks in adance,
gmail
Comment