Search code examples
c#winformsimageanchorsizing

how do I set images to scale to 100% of their table-cell? (C#/WinForms)


I have the TableLayoutControl anchored to scale with the window and the images in it need to scale with them. I am not concerned with image quality.


Solution

  • Assuming this is WinForms and you have a bunch of PictureBoxes in cells of a TableLayoutPanel, set each one's Dock to Fill and SizeMode to StretchImage.