By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
448,967 Members | 1,625 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 448,967 IT Pros & Developers. It's quick & easy.

DropDownList Refuses To Show New SelectedValue

P: n/a
I have a webform that contains a DropDownList. When the user selects a new
value and I click the submit button, the previously selected SelectedValue
property is used in my code. This is obviously preventing me from updating
my database, or even allowing the user to do anything that involves the
value of this DropDownList. What could the problem be here? I am using
ASP.NET 1.1 with Visual Studio .NET 2003 and am doing my testing with
Internet Explorer 6.0 on Windows XP Professional SP2. Thanks.
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/
Nov 1 '06 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Perhaps you're rebinding the control to your datasource in some other
event further up the stack (like init or load), and thus losing the
value that was actually posted back? Alternatively, other weird
behaviour ensues when the ID of the control changes between postbacks.

Jono

Nathan Sokalski wrote:
I have a webform that contains a DropDownList. When the user selects a new
value and I click the submit button, the previously selected SelectedValue
property is used in my code. This is obviously preventing me from updating
my database, or even allowing the user to do anything that involves the
value of this DropDownList. What could the problem be here? I am using
ASP.NET 1.1 with Visual Studio .NET 2003 and am doing my testing with
Internet Explorer 6.0 on Windows XP Professional SP2. Thanks.
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/
Nov 1 '06 #2

P: n/a
What evert are you using to get the SelectedValue? Page_Load?

"Nathan Sokalski" wrote:
I have a webform that contains a DropDownList. When the user selects a new
value and I click the submit button, the previously selected SelectedValue
property is used in my code. This is obviously preventing me from updating
my database, or even allowing the user to do anything that involves the
value of this DropDownList. What could the problem be here? I am using
ASP.NET 1.1 with Visual Studio .NET 2003 and am doing my testing with
Internet Explorer 6.0 on Windows XP Professional SP2. Thanks.
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/
Nov 1 '06 #3

P: n/a
I am placing a Response.Write() method at the end of the Click event of the
submit button. The value I am passing to the Write() method is the
DropDownList's SelectedValue property.
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/

"MarkAurit" <Ma*******@discussions.microsoft.comwrote in message
news:38**********************************@microsof t.com...
What evert are you using to get the SelectedValue? Page_Load?

"Nathan Sokalski" wrote:
>I have a webform that contains a DropDownList. When the user selects a
new
value and I click the submit button, the previously selected
SelectedValue
property is used in my code. This is obviously preventing me from
updating
my database, or even allowing the user to do anything that involves the
value of this DropDownList. What could the problem be here? I am using
ASP.NET 1.1 with Visual Studio .NET 2003 and am doing my testing with
Internet Explorer 6.0 on Windows XP Professional SP2. Thanks.
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/

Nov 1 '06 #4

This discussion thread is closed

Replies have been disabled for this discussion.