if (StringUtils.isNotEmpty(checklength))
{ // Do lengthcheck via onKeyPress and onKeyUp Events
int maxLength = (int)ci.getColumn().getSize();
checklength = StringUtils.replace(checklength, "{0}", String.valueOf(maxLength));
input.addAttribute("onkeypress", checklength);
input.addAttribute("onkeyup", checklength);
}
}
// Event Attributes
input.addAttribute("onclick", ci.getOnclick());
input.addAttribute("onchange", ci.getOnchange());