aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes auto-populate a textbox Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "auto-populate a textbox" Watch "auto-populate a textbox" New topic
Author

auto-populate a textbox

Higgledy Smith
Ranch Hand

Joined: Mar 07, 2006
Posts: 192
Does anyone know how to populate a textbox based on a value the user selects in a comboBox? For instance, when a user selects "Choice A" from the comboBox, I want the textBox to be populated with the text "GOOD CHOICE". If user selects "Choice A", the textBox is populated with "BAD CHOICE". I am really stuck. Thank you. Higgledy
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61413
    
  67

First, it's important to use proper terminology. There's no such thing as a "combo box" in HTML. Read: HtmlHasNoComboBox

Second, where's the code you've tried so far? We're more than happy to help, but we won;t write the code for you. To get you started, obviously you'll need a change handler on the select element.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: auto-populate a textbox