Make the page scrollable

Hi,
i want to set the postion of every element on my page and if the browser window is resized, scrollbars should appear on the right size and on the bottom of the browser.
Can anyone tell me how to do it?
That will be really helpfull.
Thanks.
D.

Hi,

You could wrap an AbsoluteLayout (with defined size, for example in pixels) inside a Panel (that is set to full size). This would allow for scrolling. Note that you have to use panel.setContent(absLayout) and NOT addComponent().

Using Absolutelayout you can position your elements as you wish, for example like this
absLayout.getPosition(someVaadinComponentInTheLayout).setCSSString(“top:300px;left:700px”);

Hope this helps

Hi Johan
Thanks alot. It worked fine and was simple :smiley:
ThankYou
D.

Glad to help. Good it was a valid solution :slight_smile:

// Johan