MikeMCSD
asked on
Drop Down List code
I'm populating a drop down list dynamically in code, but
I want to add this after:
Text="Select Year" Value="0" Selected="True"
<asp:DropDownList ID="ddlDOBY" runat="server">
I can do it VB but I need it in C# . . which I'm still struggling to learn. thanks
I want to add this after:
Text="Select Year" Value="0" Selected="True"
<asp:DropDownList ID="ddlDOBY" runat="server">
I can do it VB but I need it in C# . . which I'm still struggling to learn. thanks
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
that did the trick, thanks Rejo
i.e below ddlDOBY.DataBind();
write
ddlDOBY.Items.Insert(0, new listitem("0", "Select Year"));