views:

458

answers:

3

Hi

I have a Image path(some thing like this "http://ABC/XYZ/PQR.gif").And I want to assign this image to checkbox in winforms using C#.winfroms checkbox does not have SRC,How can I assign this image to checkbox.?

A: 

I'd create a User Control with your image(s) and a standard CheckBox, perhaps with no Text.

You can add an Image property to the control and the control can handle the display details.

Jay Riggs
+1  A: 

The Background of a check box can be filled with a provided image.

See

astander
+1 thanks, never thought to do this.
Jay Riggs
A: 

Try this

  1. Set the BackGroundImage Property.
  2. Change the BackGroundImageLayout Property to stretch.
  3. Change the Font Color if required
Anuraj