[Javascript] overflow: auto

David Lovering dlovering at gazos.com
Wed Apr 30 00:27:29 CDT 2003


The method you suggest is certainly the easiest.  The other is to build a 2D
array in which each row represents a row in the table.
Using createElement and deleteElement commands you could then selectively
delete rows from the top/bottom and add rows on the opposite side to
simulate scrolling, based upon the presumption that only N rows would be
visible (in addition to the header).  The data fields would be loaded from
the appropriate array values.

This would only require one real table, but would be commensurately more
complicated.

-- Dave Lovering

----- Original Message -----
From: "Walter Torres" <walter at torres.ws>
To: "[JavaScript List]" <javascript at LaTech.edu>
Sent: Tuesday, April 29, 2003 9:59 PM
Subject: RE: [Javascript] overflow: auto


> The only way I've been able to "mimic" this behaviour was to create 2
> seperate tables. One for the HEADER and another, inside an overflow
region,
> containing the data.
>
> Walter
>
> > -----Original Message-----
> > From: javascript-bounces at LaTech.edu
> > [mailto:javascript-bounces at LaTech.edu]On Behalf Of Michael Dougherty
> > Sent: Thursday, April 24, 2003 1:57 PM
> > To: javascript at LaTech.edu
> > Subject: [Javascript] overflow: auto
> >
> >
> > <span style='width: 200; height: 300; overflow: auto;'>
> >   <table>
> >     <tr>
> >       <th>Name</th>
> >       <th>Value</th>
> >     </tr>
> >     <tr>
> >       <td>Row1</td>
> >       <td>Val1</td>
> >     </tr>
> >     (many more rows)
> >   </table>
> > </span>
> >
> > Is there a convenient way to lock the table header so that it
> > doesn't scroll
> > off the visible area of it's container span?
> >
> > I would like to not have to define the widths of the columns and have a
> > fixed table with one row for the header outside the span...
> >
> >
> > _______________________________________________
> > Javascript mailing list
> > Javascript at LaTech.edu
> > https://lists.LaTech.edu/mailman/listinfo/javascript
>
> _______________________________________________
> Javascript mailing list
> Javascript at LaTech.edu
> https://lists.LaTech.edu/mailman/listinfo/javascript
>
>




More information about the Javascript mailing list