G
Guest
Hi again,
I really hope that there is a simple solution to this one, cause I'm having
simular things happening to other controls on this usercontrol. I have the
following control:
<asp
ropDownList ID="cmbOptions" runat="server" Width="195px">
<asp:ListItem Text="Search by PO ID" Value=0 Selected="True"
/>
<asp:ListItem Text="Search by Field" Value=1 />
<asp:ListItem Text="Search between dates" Value=2 />
<asp:ListItem Text="Search Most recent Num days" Value=3 />
</asp
ropDownList><br />
This would be the default list that all user would see. If a Adin logged in,
I wanted to add a few more items to the list using the follwoing code in the
usercontrol:
cmbOptions.Items.Add(New ListItem("Search by UserId", "4"))
cmbOptions.Items.Add(New ListItem("Awaiting Approval", "5"))
If I check the count before each one, and then check after, the count does
increment, but after the page re-renders, the two exrta items are not listed.
Am I missing something. This is driving me crazy. BTY, EnableViewState is
enabled for the dropdownlist control if that makes a difference in this case.
Thanks for any suggestions.
Michael
I really hope that there is a simple solution to this one, cause I'm having
simular things happening to other controls on this usercontrol. I have the
following control:
<asp
<asp:ListItem Text="Search by PO ID" Value=0 Selected="True"
/>
<asp:ListItem Text="Search by Field" Value=1 />
<asp:ListItem Text="Search between dates" Value=2 />
<asp:ListItem Text="Search Most recent Num days" Value=3 />
</asp
This would be the default list that all user would see. If a Adin logged in,
I wanted to add a few more items to the list using the follwoing code in the
usercontrol:
cmbOptions.Items.Add(New ListItem("Search by UserId", "4"))
cmbOptions.Items.Add(New ListItem("Awaiting Approval", "5"))
If I check the count before each one, and then check after, the count does
increment, but after the page re-renders, the two exrta items are not listed.
Am I missing something. This is driving me crazy. BTY, EnableViewState is
enabled for the dropdownlist control if that makes a difference in this case.
Thanks for any suggestions.
Michael