T
tshad
I have a dropdownbox object:
<aspropDownList ID="ddlQuestionType" runat="server">
<asp:ListItem Value="MS" Text="Multiple Single" />
<asp:ListItem Value="MM" Text="Multiple Multiple" />
<asp:ListItem Value="TF" Text="True/False" />
</aspropDownList>
The values and text are static. I am reading from a table:
Select QuestionType from myTable where id = 10
and QuestionType will either be "MS", "MM" or "TF".
How do I bind the data to this object?
With a Label it would be something like:
<asp:label id="Question" Text='<%# DataBinder.Eval(Container.DataItem,
"QuestionUnique") %>' runat="server" />
Thanks,
Tom.
<aspropDownList ID="ddlQuestionType" runat="server">
<asp:ListItem Value="MS" Text="Multiple Single" />
<asp:ListItem Value="MM" Text="Multiple Multiple" />
<asp:ListItem Value="TF" Text="True/False" />
</aspropDownList>
The values and text are static. I am reading from a table:
Select QuestionType from myTable where id = 10
and QuestionType will either be "MS", "MM" or "TF".
How do I bind the data to this object?
With a Label it would be something like:
<asp:label id="Question" Text='<%# DataBinder.Eval(Container.DataItem,
"QuestionUnique") %>' runat="server" />
Thanks,
Tom.