PDA

View Full Version : Scrollbars?


Tanker
08-12-2002, 06:16 PM
New info: wrote previous post while in a hurry for a mtg.

We have a search box that opens in a pop up box with no scrollbars. If the search result is more than 1 record we reload this same page with the results in a table, resize the window to accomadate the data, and then move it to recenter it on the screen.

We are dynamically resizing the height of the window depending on how many records are returned, if the dynamic height is greater than 480 we are setting it to 480 so we don't get windows that are unreadable.

Since we turned the scrollbars off in the popup window when we loaded it they are still gone. Is there a way to turn them back on if the height of the page exceeds 480 or will we need to close that popup and open a new one to get the scrollbars back?

[EDIT:]Original Message...
Is it possible to turn scrollbars on and off without reloading the
current page?

beetle
08-12-2002, 08:59 PM
Unless someone can prove me wrong (because I don't know impirically), you can't dynamically add/subtract window elements (scrollbars, menubar, statusbar, etc) They can only be set at window creation. I am 99.99% sure of this. :D

Algorithm
08-12-2002, 10:20 PM
beetle's right, you can't add scrollbars once the window's created. Even so, there are still ways of acheiving what you're looking for. The simplest way I can think of is to load your second page in a frameset, with the frame's scrolling set to "auto".

Hope that helps.

A1ien51
08-13-2002, 05:03 AM
try playing with this

document.body.style.overflow="hidden";
document.body.style.overflow="visible";