Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Chrome - overflow='auto'

Posted on 2010-08-25
10
Medium Priority
?
1,041 Views
Last Modified: 2013-12-07
Hi,
I have a WEB site (WEB application) that is a table of boxes (<table><tr><td>...)
In several boxes there are "grig tables" that may have many lines.
I don't want the boxes to expand so I set it as
obj.style.overflow='auto';
and
obj.style.hieght=155;

I works very weel in IE - when there are more lines then it can hold it adds a vertical scrollbar.
But in Chrome (and FireFox) it does not add the scrollbar and expands the box height.

 
0
Comment
Question by:VapiSoft
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 4
10 Comments
 
LVL 40

Expert Comment

by:Gurvinder Pal Singh
ID: 33522366
you need to give overflow:scroll
http://www.w3schools.com/css/pr_pos_overflow.asp

if doesn't work, then also try adding
overflow-x:scroll
overflow-y:scroll
0
 

Author Comment

by:VapiSoft
ID: 33522954
I tried all but nothing works.
0
 

Author Comment

by:VapiSoft
ID: 33523306
I checked it with firburg (for firefox) and what I see that although I do
obj.style.height=155;
the width="100%".
So I understand that this is not the way to set the height.
0
Build and deliver software with DevOps

A digital transformation requires faster time to market, shorter software development lifecycles, and the ability to adapt rapidly to changing customer demands. DevOps provides the solution.

 
LVL 40

Expert Comment

by:Gurvinder Pal Singh
ID: 33523751
check for the typo here, it should be
obj.style.height=155;

0
 

Author Comment

by:VapiSoft
ID: 33523935
I don't see any difference between what I wrote and what you wrote.
I don't see any typo.
0
 
LVL 40

Accepted Solution

by:
Gurvinder Pal Singh earned 1500 total points
ID: 33523976
hmm..i was referring to what you wrote in original question.

If you are setting the height to a cell or a row of a table you can do it by
obj.setAttribute("height", "155px");
0
 
LVL 54

Expert Comment

by:b0lsc0tt
ID: 33524136
The expert showed this in the example but to emphasize your height needs units.  Most likely pixels.  E.g.obj.style.height = 155px;bol
0
 

Author Comment

by:VapiSoft
ID: 33524147
I found out that the problem is in another place that afterwards I change the the heigth="100%".
I am sorry and I will give you the points for trying to help.
0
 

Author Closing Comment

by:VapiSoft
ID: 33524162
As I wrote, it was my mistake.
0
 
LVL 40

Expert Comment

by:Gurvinder Pal Singh
ID: 33524215
Thanks for the points :)
0

Featured Post

The top UI technologies you need to be aware of

An important part of the job as a front-end developer is to stay up to date and in contact with new tools, trends and workflows. That’s why you cannot miss this upcoming webinar to explore the latest trends in UI technologies!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Citrix XenApp, Internet Explorer 11 set to Enterprise Mode and using central hosted sites.xml file.
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
This Micro Tutorial will demonstrate how nuggets on the Web are formatted by using Chrome Developer Tools. These tools would not only view the site's CSS but it can also modify it and save the CSS to use on your own site.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question