I have this CheckBoxList on a page:
Easy Way I Do It.
//First create query directly From Database that contains hidden field code format (i do it in stored procedure)
SELECT Id,Name + '' as Name FROM User
//Then bind checkbox list as normally(i bind it from dataview).
cbl.DataSource = dv;
cbl.DataTextField = "Name";
cbl.DataValueField = "Id";
cbl.DataBind();
//Then finally it represent code as follow.
This way you can get DataValueField as inside hiddenfield and also can get it value from client side using javascript.