Changing Select Options

Results 1 to 2 of 2

Thread: Changing Select Options

  1. #1
    Join Date
    Dec 1969

    Default Changing Select Options

    Is there any way to change the number of options in a select box instead of just overwriting them. I am trying to update a select box based on the onChange of another, however the new select values may be much smaller in number, and I would like to do without the empty space. Conversely If I start with small number of options can I add options to a select box. How is this accomplished? Thanks for your help

  2. #2
    Join Date
    Dec 1969

    Default RE: Changing Select Options

    It certainly can be done in IE at least. There are at least 2 ways:<BR><BR>1. The options collection of a select object has 2 useful methods: add() and remove(). See for detials (seems to be broken today though).<BR><BR>2. You can change the innerHTML property of the select object.<BR><BR>Dunc

Posting Permissions

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