Community discussion forum

Dynamically Adding OPTIONS to SELECT

This is a comment thread discussing Dynamically Adding OPTIONS to SELECT
  • 9 years ago

    This thread is for discussions of Dynamically Adding OPTIONS to SELECT.

  • Advertisement

    Simply the fastest line-level profiler for .NET ever

    “The low overhead means it has minimal impact on the execution of my program”
    Mark Everest, Development Team Leader, Renault F1 Team Ltd.

    Try out the new ANTS Profiler 4 for yourself. Download your 14-day trial now

  • 3 years ago

    Hi!


    Great simple code for adding Options to a SELECT.


    Is it possible to create the SELECT element as well?


    I need to add rows dynamycally to a table, and in one TD of each row there should appear a SELECT.


    Thanks!

  • 2 years ago

    I tried this using IE, and a get an error saying "invalid argument".

  • 1 year ago

    In order for this to work in both FF and IE it needs to be .innerHTML (instead of .innerText).
    Oh and classic VB developers have to watch out for case sensitive javascript...
    it need to be .value (instead of .Value)



Post a reply

Enter your message below

Sign in or Join us (it's free).