C# 更改tableLayoutpanel的单元格(背景颜色和背景图像)
问题1: 我想直接从Properties.Resource.image在TableLayoutPanel的单元格中添加一个图像C# 更改tableLayoutpanel的单元格(背景颜色和背景图像),c#,tablelayoutpanel,C#,Tablelayoutpanel,问题1: 我想直接从Properties.Resource.image在TableLayoutPanel的单元格中添加一个图像 tableLayoutPanel1.Controls.Add(Properties.Resource.image,column,row); //cell backround should be covered with image 问题2: 我想改变细胞背面颜色简单的风格 tableLayoutPanel1.Position(column,row).backrou
tableLayoutPanel1.Controls.Add(Properties.Resource.image,column,row);
//cell backround should be covered with image
问题2:
我想改变细胞背面颜色简单的风格
tableLayoutPanel1.Position(column,row).backroundcolor=Color.Red;
不是那个话题,我甚至不能这样做。
TableLayoutPanel 1.控件。添加
需要一个控件。我如何解决它的问题?使用一个可以显示图像的控件,如PictureBox。你可以显示,我可以怎么做吗?在设计时,将PictureBox
放入单元格,将其Dock
属性设置为Fill
,并检查图片框的其他属性。特别是背景色
,图像
,尺寸模型
,背景图像
,以及背景图像布局
。