Web control with horozontal scrolling

G

Gaetan

I have some log data maintained in a DB that I would like to display on a web page. Some rows of the
DB table are wider than the web page therefore horizontal scrolling will be required to view the
data.

I cannot use a ListBox web control since it does not support horizontal scrolling. In ASP.Net 2.0,
what type of web control can I use to allow horizon scrolling of rows larger than the web page?

PS, some article on the web indicates that I could hack something with <DIV> and JavaScript code but
I would like to avoid that if possible.

G.
 
B

bruce barker \(sqlwork.com\)

the panel will suppport scrolling. as this is just a div with overflow
style, you must set an absolute size for the scollbars to appear. this
generally means you need client script to resize it to the window size.

note: some will suggest setting width to 100%, but this only valid if inside
another element with an absolute size. older versions of IE supported 100%
without, but its not html 4.0 or xhtml compliant, so you would have to run
in tweaks mode. also any complex markup broke it anyway.

if you re writing web apps, you should learn javascript and the dom.

-- bruce (sqlwork.com)
 
G

Guest

your options would be:

1) Use a TEXTAREA (Textbox control that's set for multiline). You'll
probably want to disable it.
2) surround your label with a <div style="width: 200px; height: 36px;
overflow: auto">
3) create a css style for your label that defines "width: 200px; height:
36px; overflow: auto; display: inline-block"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,813
Latest member
lawrwtwinkle111

Latest Threads

Top