Hi,
try this
function f2(tid) {
if (confirm("Are you Sure?")) {
}
else {
document.getElementById(tid).checked = false;
}
And design
<table width="50%" align="center" id="dt1">
<tr> <td> <input type="checkbox" id="ch1" onclick="f2(this.id)" />
</td>
</tr>
<tr>
<td>
<input type="checkbox" id="ch2" onclick="f2(this.id)" />
</td>
</tr>
<tr>
<td>
<input type="checkbox" onclick="f2(this.id)" />
</td>
</tr>
<tr>
<td>
<input type="checkbox" />
</td>
</tr>
</table>
All the Best