Can someone post a complete example of Q2 2011 for making this work .... I have the other events working including OnClientSelectedIndexChanged, OnClientItemsRequesting, OnClientDropDownClosing
My problem is the OnClientItemDataBound event does not seem to be firing ... I have a somewhat 'different' scenario in that the events are wired up in the code behind and the script as well so
so in the page load
void Page_Load()
{
if(!this.IsPostBack)
{
mycombobox.OnClientItemDataBound = "mycombobox_OnClientItemDataBound"
}
RegisterScripts();
}
then register scripts looks like
private void RegisterScripts()
{
StringBuilder sb = new StringBuilder()
sb.AppendLine("function mycombobox_OnClientItemDataBound(sender, args){console.log(sender);}")
ScriptManager.RegisterStartupScript(Page, Page.GetType(), "name", sb.ToString(), true);
}
the 'binding code looks like this'
[item generation code]
mycombobox.DataSource = items;
mycombobox.DataBind()
My problem is the OnClientItemDataBound event does not seem to be firing ... I have a somewhat 'different' scenario in that the events are wired up in the code behind and the script as well so
so in the page load
void Page_Load()
{
if(!this.IsPostBack)
{
mycombobox.OnClientItemDataBound = "mycombobox_OnClientItemDataBound"
}
RegisterScripts();
}
then register scripts looks like
private void RegisterScripts()
{
StringBuilder sb = new StringBuilder()
sb.AppendLine("function mycombobox_OnClientItemDataBound(sender, args){console.log(sender);}")
ScriptManager.RegisterStartupScript(Page, Page.GetType(), "name", sb.ToString(), true);
}
the 'binding code looks like this'
[item generation code]
mycombobox.DataSource = items;
mycombobox.DataBind()