Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
715
Scroll Bar in GridBagLayoutPanel
posted

Hi,

When i am adding more controls to GridBagLayoutPanel, Instead of scroll bar coming, controls in GridBagLayoutPanel are getting compressed to smaller size. what should i do so that scroll bar appears and controls are not compressed than actual size.

 

Thanks,

KK

  • 469350
    Verified Answer
    Offline posted

     Hi KK,

        I don't think this is supported. The whole concept of a GridBagLayout is that it positions the controls inside the available area.

        I guess what you could do is make the GridBagLayoutPanel as big as you want and then place it inside another panel with AutoScroll set to true on the outer panel.