R
Richard Morse
Hi! I'm trying to use a DropDownList in an .aspx file that bases data
off of a database. I'm using the .NET Framework 1.1. According to the
documentation, I should be able to assign a value to the SelectedValue
property, and this would tell the DropDownList to use a particular value
as the initial display value.
This is being done in a Repeater.
However, it doesn't seem to work -- that is, nothing gets set to be the
initial value, so it always uses the first value in the menu.
In an attempt to fix this, I tried to insert javascript on the client,
using the "ClientID" property to properly select the item and set the
value this way (which is more of a problem). However, the ClientID
always is just the control name -- none of the rest of the ID that
serves to differentiate it from the other "site_id"s created by the
repeater.
Has anyone seen anything like this before? Any ideas of how I can get
the SelectedValue property working (which would be my preference)?
Thanks,
Ricky
off of a database. I'm using the .NET Framework 1.1. According to the
documentation, I should be able to assign a value to the SelectedValue
property, and this would tell the DropDownList to use a particular value
as the initial display value.
This is being done in a Repeater.
However, it doesn't seem to work -- that is, nothing gets set to be the
initial value, so it always uses the first value in the menu.
In an attempt to fix this, I tried to insert javascript on the client,
using the "ClientID" property to properly select the item and set the
value this way (which is more of a problem). However, the ClientID
always is just the control name -- none of the rest of the ID that
serves to differentiate it from the other "site_id"s created by the
repeater.
Has anyone seen anything like this before? Any ideas of how I can get
the SelectedValue property working (which would be my preference)?
Thanks,
Ricky