Getting a value from a form/listbox

Results 1 to 2 of 2

Thread: Getting a value from a form/listbox

  1. #1
    Jeff Pretz Guest

    Default Getting a value from a form/listbox

    I am trying to pull the string value from a listbox on a form and not getting it. I thought it was as easy as:<BR>document.form.listboxname.value but that does not work. Looking at some references I&#039ve also tried using variations of document.ListBox1.getText(selectedIndex) an others.<BR><BR>Basically all I want is to pull the currently selected item value in a listbox and use it in a variable elsewhere.<BR><BR>Any help would be appreciated.

  2. #2
    N. Juergenson Guest

    Default RE: Getting a value from a form/listbox

    Jeff, <BR><BR>Try using this:<BR><BR>&#060;% variable=Request.Form("ListBoxName") &#037;&#062;<BR><BR>This should take the value selected in a list box in a form and display it as the variable value. This variable can then be used throughout your application.<BR><BR>Let me know if this helps

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •