Checkbox onclick is not working in IE8 but working in IE9
<p>I'm creating dynamic checkbox and attaching onclick event with that. Below is the code:</p>

<pre><code>var table = document.getElementById(tableID);
var rowCount = table.rows.length;
var row = table.insertRow(rowCount);

var cell1 = row.insertCell(0);
var checkbox = document.createElement("input");
checkbox.type = 'checkbox';
checkbox.onclick = testClick();
cell1.appendChild(checkbox);

function testClick() {
            alert("Hello");
}
</code></pre>

<p>The above piece of code is working fine with IE9 but not with IE8. I'm using Jquery 1.7.1.</p>

<p>Any help will be greatly appreciated. Thanks..</p>
