473,396 Members | 1,773 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Drop Down List - is this normal behaviour?

G

I have the following DropDownList on my webform.

<asp:DropDownList ID="MyStatus" CssClass="DropDownList"
runat="server">
<asp:ListItem Value="" Text="Please select"></asp:ListItem>
<asp:ListItem Value="0" Text="Where's the nearest
bridge?">Where's the nearest bridge?"></asp:ListItem>
<asp:ListItem Value="1" Text="Been better.">Been
better.</asp:ListItem>
<asp:ListItem Value="1" Text="Feeling chirpier than
usual">Feeling chirpier than usual</asp:ListItem>
<asp:ListItem Value="1" Text="Fantastic, Amazing, On top of
the world!">Fantastic, Amazing, On top of the world!"></asp:ListItem>
<asp:ListItem Value="1" Text="Bloody marvelous!">Bloody
marvelous!</asp:ListItem>
<asp:ListItem Value="1" Text="Absolutely
Euphoric">Absolutely Euphoric</asp:ListItem>
</asp:DropDownList>

In code behind, if I try to capture the SelectedText, I am unable to capture
anything other than "Where's the nearest bridge" or "Been better", which is
returned for everything except the first selection.

Does .NET not distinguish between the various drop down options when they
have an identical "value"?

Any advice appreciated.

G.

Mar 2 '07 #1
1 1073
"G" <g@nospam.comwrote in message
news:91**********************************@microsof t.com...
Does .NET not distinguish between the various drop down options when they
have an identical "value"?
No.
Any advice appreciated.
Give each <asp:ListItema unique value.
Mar 2 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: deko | last post by:
I populate a drop-down list like this: echo "<select>"; foreach ( $ip_list as $var ) { echo "<option>"; echo $var; echo "</option>"; } echo "</select>";
6
by: Filiz Duman | last post by:
I was just wondering, is it possible to write into the drop down box in order to jump to a specific item. The reason why I am asking is my drop down box has many items and additionally to the...
3
by: Matt | last post by:
I want to know if readOnly attribute doesn't work for drop down list? If I try disabled attribute, it works fine for drop down list. When I try text box, it works fine for both disabled and...
4
by: Yuk Cheng | last post by:
<<<start index.htm>>> <html> <head> <script> function perform(action){ } </script> </head>
2
by: hemanth.singamsetty | last post by:
Hello there, I've a drop down menu (created using CSS & Javascript -- see code below). My problem is, whenever I click a link on the menu the new page replaces the current page (and the menu...
1
by: rewf | last post by:
Hi, I fave this problem with a drop down list: I have a drop down list that work with a database. In the database I have some word with some spaces before like that "Example Example" My problem...
1
by: StevePBurgess | last post by:
Hi I am using a drop down menu adapted from the one in Stylin with CSS by Charles Wyke Smith. The CSS is below. It works perfectly in Internet Explorer (using the csshover behaviour file) but...
1
by: abTech | last post by:
Have struggled a lot to get a filtered drop down in the normal html and that too editable ... i have used table like auto-completion etc ... This is the simplest solution for a filtered drop down ...
0
by: mjohnson0321 | last post by:
I am trying to incorporate a CSS drop-down menu into a site (suckerfish menu). The menu gets lost behind the content below it, but only on one of the drop downs (News). The error occurs on all of...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.