Try below..
Script part
<script src="jquery-1.4.2.js" type="text/javascript"></script>
<script type="text/javascript">
$(document).ready(function()
{
$('.chkAll').click(function()
{
$("INPUT[type='checkbox']").attr('checked',$('#MychkAll').is(':checked'));
});
});
</script>
Html part..
<asp:CheckBox ID="MychkAll" class="chkAll" runat="server" Text="Check All" />
<asp:CheckBoxList ID="MyCbList" runat="server">
<asp:ListItem Text="Item 1" Value="1"></asp:ListItem>
<asp:ListItem Text="Item 2" Value="2"></asp:ListItem>
<asp:ListItem Text="Item 3" Value="3"></asp:ListItem>
<asp:ListItem Text="Item 4" Value="4"></asp:ListItem>
</asp:CheckBoxList>