Hello! I have been trying to get data bound to a textbox nested inside an ItemTemplate to no avail. I have attempted to bind it in code behind by looping through items in the list, as well as in the ASP and I am coming up with no answers.
As you can see below, I have three cells in the ComboBox, and I have no problems loading the combobox items not bound to asp objects. The problem is that I am unable to bind values to the nested asp:CheckBox and asp:TextBox.
The text in the section <%# DataBinder.Eval(Container, "Value")%> is all black, not three tone as is normal in VS2010.
It's almost as one cannot bind data to ASP items in an ItemTemplate. Is that correct?
Here is the ASP. If this is possible, what am I doing wrong?
Thanks in advance!
As you can see below, I have three cells in the ComboBox, and I have no problems loading the combobox items not bound to asp objects. The problem is that I am unable to bind values to the nested asp:CheckBox and asp:TextBox.
The text in the section <%# DataBinder.Eval(Container, "Value")%> is all black, not three tone as is normal in VS2010.
It's almost as one cannot bind data to ASP items in an ItemTemplate. Is that correct?
Here is the ASP. If this is possible, what am I doing wrong?
Thanks in advance!
<
telerik:RadComboBox
runat
=
"server"
ID
=
"ddlHardCopies"
HighlightTemplatedItems
=
"true"
Width
=
"250px"
AllowCustomText
=
"True"
>
<
ItemTemplate
>
<
table
>
<
tr
>
<
td
>
<
asp:checkbox
runat
=
"server"
ID
=
"chkHardCopy"
onclick
=
"stopPropagation(event);"
Text='<%# DataBinder.Eval(Container, "Value")%>'/>
</
td
>
<
td
>
<
asp:TextBox
runat
=
"server"
ID
=
"txtHardCopyQuantity"
onclick
=
"stopPropagation(event);"
Width
=
"20px"
Text='<%# DataBinder.Eval(Container, "Quantity")%>'/>
</
td
>
<
td
>
<%# DataBinder.Eval(Container, "Text")%>
</
td
>
</
tr
>
</
table
>
</
ItemTemplate
>
</
telerik:RadComboBox
>