Solved

Simple Question

Posted on 1998-07-20
2
170 Views
Last Modified: 2010-04-09
Hi Experts, I have created a list cob/Combo Box (Select and Option Tags)
  for a textfield, using VBScript, I can retrieve the data by
  document.FormName.elements(1).Value
 so for a combo/list box, how should I retrieve ?
Thanks
0
Comment
Question by:seahpc
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 28

Accepted Solution

by:
sybe earned 50 total points
ID: 1844754
document.form_name.field_name.options[document.form_name.field_name.selectedIndex].value

Or if you use an 'onChange":

onChange="MyFunction(this.options[this.selectedIndex].value)"
0
 
LVL 2

Author Comment

by:seahpc
ID: 1844755
I found the answer a bit different from yours :
document.form_name.field_name.optionsCdocument.form_name.field_name.selectedIndex).text
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes how to create custom column layout styles for Bootstrap. The article uses 5 columns to illustrate the concept, but the principle can be extended to any number of columns.
Find out what you should include to make the best professional email signature for your organization.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

697 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question