Hi sir ,
In my vaadin application , i need to set [b]
scrollbar
[/b] to
panel
which contains
verticallayout
which contains
absolutelayout
.
I set the panel as setScrollable(true) and setScrolltop(1600). what the problem is that i have changed the height of the both
verticallayout
and
absolutelayout
greater than
panel
height . That’s why
panel
creating
scrollbar
. If i reduce the height of
vertical
and
absolutelayout
to lower than
panel
height, then scroll in
panel
disappear. Please give some solution.
This is my code
[code]
private Panel buildPanel_2()
{
// common part: create layout
panel_2 = new Panel();
panel_2.setImmediate(true);
panel_2.setHeight("700px");
panel_2.setScrollable(true);
panel_2.setScrollTop(1600);
verticalLayout_2 = buildVerticalLayout_2();
panel_2.setContent(verticalLayout_2);
return panel_2;
}
@AutoGenerated
private VerticalLayout buildVerticalLayout_2()
{
// common part: create layout
verticalLayout_2 = new VerticalLayout();
verticalLayout_2.setImmediate(true);
verticalLayout_2.setMargin(false);
verticalLayout_2.setWidth("1000px");
verticalLayout_2.setHeight("2000px");
absoluteLayout_5 = buildAbsoluteLayout_5();
verticalLayout_2.addComponent(absoluteLayout_5);
return verticalLayout_2;
}
@AutoGenerated
private AbsoluteLayout buildAbsoluteLayout_5()
{
// common part: create layout
absoluteLayout_5 = new AbsoluteLayout();
absoluteLayout_5.setImmediate(false);
absoluteLayout_5.setWidth("1000px");
absoluteLayout_5.setHeight("2000px");
absoluteLayout_5.setMargin(false);
//
return absoluteLayout_5;
}
[/code]
Thank you sir.