Quantcast
Channel: DevNet Questions
Viewing all articles
Browse latest Browse all 8832

Unigrid OnExternalDataBound's checkbox controls don't get refreshed after sorting

$
0
0
Hi Kentico, There is a an issue with customized check-boxes in unigrid control as below: when I use checkbox control within OnExternalDataBound function, everything is OK except when I click on any sort links, the value of check boxes remain the same!? protected object unigridXXX_OnExternalDataBound(object sender, string sourceName, object parameter) { var drv = (DataRowView)parameter; var obj = (DataControlFieldCell)sender; int reviewId = ValidationHelper.GetInteger(drv.Row["ItemID"], 0); bool isExcludedFromEmail = ValidationHelper.GetBoolean(drv.Row["EmailExclusion"], false); if (sourceName.ToLower() == "excludedemail") { CheckBox chkEmailExclusion = new CheckBox(); chkEmailExclusion.Enabled = true; if (isAdmin || (isTrainingAdmin)) { chkEmailExclusion.ID = "chkEmailExclusion"; chkEmailExclusion.TextAlign = TextAlign.Left; chkEmailExclusion.Enabled = false; chkEmailExclusion.CssClass = "excluded-email"; chkEmailExclusion.Checked = isExcludedFromEmail; } return chkEmailExclusion; } } Please let me know if this is a known bug and there is a workaround for that. Current Kentico version: 8.2.16 Thanks,

Viewing all articles
Browse latest Browse all 8832

Trending Articles