Search code examples
c#winformspicturebox

How to unset an image from a picturebox in c#?


I have a picturebox that is intended to have different kinds of images based on the situation. On the other way around, it must have no picture when it's not needed. How to unset an image from that picturebox in c#?


Solution

  • Use the Image property to set the image to display.

    Set it to null to display nothing.