DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 3 of 3

Thread: Having a ListBox to display field content from database

  1. #1
    Philip Guest

    Having a ListBox to display field content from database


    Hi,

    Could anyone tell me how is it that put a ListBox into a HTML page to diplay
    contents of a certain database field?

    Is there any html tag for it or should i use a windows predefine classid
    for it?

    phil

  2. #2
    Russell Jones Guest

    Re: Having a ListBox to display field content from database

    The HTML equivalent to a ListBox is a <select> element. By default, it looks
    like a read-only combobox, but if you add a size=10 attribute, you'll get a
    listbox 10 items tall.

    "Philip" <philcp@yahoo.com> wrote in message
    news:3b2880d4$1@news.devx.com...
    >
    > Hi,
    >
    > Could anyone tell me how is it that put a ListBox into a HTML page to

    diplay
    > contents of a certain database field?
    >
    > Is there any html tag for it or should i use a windows predefine classid
    > for it?
    >
    > phil




  3. #3
    Matt Markus Guest

    Re: Having a ListBox to display field content from database

    Hi Russell --


    "Russell Jones" <arj1@northstate.net> wrote in message
    news:3b299225@news.devx.com...
    > The HTML equivalent to a ListBox is a <select> element. By default, it

    looks
    > like a read-only combobox, but if you add a size=10 attribute, you'll get

    a
    > listbox 10 items tall.
    >
    > "Philip" <philcp@yahoo.com> wrote in message
    > news:3b2880d4$1@news.devx.com...
    > >
    > > Hi,
    > >
    > > Could anyone tell me how is it that put a ListBox into a HTML page to

    > diplay
    > > contents of a certain database field?
    > >
    > > Is there any html tag for it or should i use a windows predefine classid
    > > for it?
    > >
    > > phil

    >
    >


    'here
    <select name=lstEmployees size=10>
    Do while not rst.eof
    <option value=<%=rst("EmpID")%>>
    <%=rst("EmpLastName")%></option>

    rst.MoveNext
    Loop

    </select>




Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center