Remove scrollbars caused by multi-sheet panel

Not really an issue, more of a huge annoyance.

I’m customizing our Order Entry screen by expanding our comments box. While trying to make more room for the boxes I noticed there was a scroll bar on the panel at the bottom. So I expanded the panel size, which eliminated the scrollbar by the panel but now I have a scroll bar on my form… No matter what I do I can’t get the scrollbar to go away completely, it’s in either on the form or on the panel. Shrink the panel, the panel gets the scrollbar, expand the panel, my form gets the scrollbar. Ugh…

What doesn’t make sense to me is I made sure there were no hidden controls out of bounds of the panel or form and I’m still getting a scrollbar. Is there anyway I can tell my form to not display scrollbars at all? (with the exception of ultragrids)

Found a solution, posting in case anyone else stumbles into a similar issue. For my case I did not restore autoscroll, as there’s nothing to scroll to.

// need to disable AutoScroll, otherwise disabling the horizontal scrollbar doesn't work
summaryPanel1.AutoScroll = false;

// disable horizontal or vertical scrollbar
summaryPanel1.VerticalScroll.Enabled = false;

// restore AutoScroll
summaryPanel1.AutoScroll = true;