Option selected index : Option Select ComboBox « Form Control « JavaScript DHTML

JavaScript DHTML
1. Ajax Layer
2. Data Type
3. Date Time
4. Development
5. Document
6. Dojo toolkit
7. Event
8. Event onMethod
9. Ext JS
10. Form Control
11. GUI Components
12. HTML
13. Javascript Collections
14. Javascript Objects
15. Javascript Properties
16. jQuery
17. Language Basics
18. Mochkit
19. Mootools
20. Node Operation
21. Object Oriented
22. Page Components
23. Rico
24. Scriptaculous
25. Security
26. SmartClient
27. Style Layout
28. Table
29. Utilities
30. Window Browser
31. YUI Library
Java
Java Tutorial
Java Source Code / Java Documentation
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
JavaScript DHTML » Form Control » Option Select ComboBox 
Option selected index
   
<html>
<head>
<script language="JavaScript">
<!--
function selectChange() {
   selIdx = document.forms[0].marsupials.selectedIndex;
   newSel = document.forms[0].marsupials.options[selIdx].text;
   alert("Selection has changed to: " + newSel);
}
//-->
</script>
</head>
<body>
<basefont size=4>
<form>
Please choose a city:
<select name="marsupials" onChange="selectChange()">
<option>A
<option>B
<option>C
</select>
</form>
</body>
</html>

           
         
    
    
  
Related examples in the same category
1. Set select to multiple selected
2. Options in select
3. Option label
4. Option default Selected Example
5. Option selected Index Example
6. Option selected
7. Is Select a select-multiple
8. 'index' Example
9. 'value' Example
10. Add an option to select
11. 'text' Example
12. Auto Linked Option Listbox without button
13. Triggering a Value Change from a Pop-Up Menu
14. Cycling through a Multiple-Selection List
15. Modifying optgroup Element Labels
16. Grouped selection control on change event
17. Change background
18. Changing Select Element Content (two Combobox)
19. Drop-down Redirect - No Submit button
20. Drop-down Redirect - Submit
21. Dropdown list (combobox) in a form
22. dropdown list (combobox) in form 2
23. Disable or enable an option
24. Disable and enable a dropdown list (combobox)
25. Return the name of the form that contains dropdown list (combobox)
26. Number of options in the dropdown list(Combobox)
27. Change the size of a dropdown list (ComboBox)
28. Select multiple options in a dropdown list (option)
29. Return the selected option as text in option
30. Return the selected option as a number
31. Change the option text
32. Remove an option from a dropdown list (combobox)
33. Methods and Properties of the Select Object
34. Properties of the Option Object
35.  Using the Location object to change another frame's URL
36. Using a Summary Form to Support Local Processing
37. Navigating with a SELECT Object
38. Using the selectedIndex Property
39.  Modifying OPTGROUP Element Labels
40. Using the options[index].text Property
41.  Using the options[index].value Property
42. Triggering a Color Change from a Pop-Up Menu
43. Modifying SELECT Options
44. Modifying SELECT Options (IE4+)
45. Modifying SELECT Options (NN6+)
46. Selecting an Option Using JavaScript
47. Linked ComboBox (option) Country =- province
48. ComboBox set value to TextField
49. Menu(Option) Generator
50. URL Option ComboBox
51. Show Selected Option items
52. Click button to navigate to selected url from form select control
53. Set the select control value
54. Add or remove options from select form control
55. Get changed selection from form select
56. Demonstrates select object used as a multi-line list box
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.