How to disable horizontal scrollbar for table panel in winforms

前端 未结 9 1086
栀梦
栀梦 2020-12-10 11:54

Hi I\'ve a tablelayoutpanel and I\'m binding controls to it dynamically. When the item count exceeds the height of panel obviously vertical scroll bar appearing there is no

9条回答
  •  攒了一身酷
    2020-12-10 12:19

    int vertScrollWidth = SystemInformation.VerticalScrollBarWidth;
    
    tableLayoutPanel1.Padding = new Padding(0, 0, vertScrollWidth, 0);
    

提交回复
热议问题