Hi,
I have a PNG image (round button) and I want to use that as button. I have tried setting the image property to that image in radButton control but it shows the transparent area as well. My Question is how can I use round images as buttons and is the procedure for using transparent images same for all controls?
Thanks
Afraz Ali
I have a PNG image (round button) and I want to use that as button. I have tried setting the image property to that image in radButton control but it shows the transparent area as well. My Question is how can I use round images as buttons and is the procedure for using transparent images same for all controls?
Thanks
Afraz Ali
5 Answers, 1 is accepted
0
Hello Afraz Ali,
Our image handling mechanism is the same as the standard WinForms controls. Try adding a transparent image to the standard button and use the same logic in the Telerik WinForms button.
Greetings,
Vassil
the Telerik team
Our image handling mechanism is the same as the standard WinForms controls. Try adding a transparent image to the standard button and use the same logic in the Telerik WinForms button.
Greetings,
Vassil
the Telerik team
Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Public Issue Tracking
system and vote to affect the priority of the items
0

Afraz Ali
Top achievements
Rank 1
answered on 15 Sep 2010, 05:09 AM
Hi Vassil ,
Could you please tell me a step by step mechanism for this?
Regards,
Syed Afraz Ali
Could you please tell me a step by step mechanism for this?
Regards,
Syed Afraz Ali
0
Hi Afraz Ali,
Although this question is not related to our tools, we will address it any way, just to help you out.
As noted, the steps to set an image in our tools is the same as setting an image in the standard MS controls. If you see the transparent area, then either your image is not transparent, or you have not set its background color to be transparent. The latter can be done through an ImageList:
If you still experience problems, please review the Microsoft Developer Network (MSDN) on how to work with transparent images.
Greetings,
Stefan
the Telerik team
Although this question is not related to our tools, we will address it any way, just to help you out.
As noted, the steps to set an image in our tools is the same as setting an image in the standard MS controls. If you see the transparent area, then either your image is not transparent, or you have not set its background color to be transparent. The latter can be done through an ImageList:
- Add an ImageList component to your form
- Load the images into an imagelist.
- Go to the ImageLlist's properties and change the TransparentColor property to the background color that you would like to be transparent.
- Set ColorDepth to your png's color depth, usually Depth8Bit
- Assign the ImageList to the button via the button's ImageList property
- Go to the button's ImageKey property and select the image you would like to display
- Run the application to see the result
If you still experience problems, please review the Microsoft Developer Network (MSDN) on how to work with transparent images.
Greetings,
Stefan
the Telerik team
Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Public Issue Tracking
system and vote to affect the priority of the items
0

Piyush Bhatt
Top achievements
Rank 2
answered on 13 Jul 2011, 01:12 PM
as a 'sold' product, it would be a great benefit if the RadButton had off-the-shelf feature to make it look like an image button w/o much settings.
I am also trying to set an image on the regular button and rad button - so that I can see just the image - but both of them show some background control color and not able to make it transparent. I set the control's BackColor property as well - but no luck.
I am also trying to set an image on the regular button and rad button - so that I can see just the image - but both of them show some background control color and not able to make it transparent. I set the control's BackColor property as well - but no luck.
0
Hello Piyush,
Thank you for writing.
You can set an image to RadButton and display only the image with two lines of code:
I hope this helps.
Kind regards,
Stefan
the Telerik team
Thank you for writing.
You can set an image to RadButton and display only the image with two lines of code:
button.Image = Image.FromFile(@
"C:\image.png"
);
button.AutoSize =
true
;
I hope this helps.
Kind regards,
Stefan
the Telerik team
Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!