Decrease Font Size
Increase Font Size
   BLOG

Individualizing the Control: Add a custom toolbox icon for the control

Individualizing the Control: Add a custom toolbox icon for the control

How to add icon to custom server control

  1. Create an icon from any of the links below. This is free.

    genfavicon

    dynamicdrive

  2. What is the name of your class? For instance my class name is TextScroller

    public class TextScroller : WebControl, INamingContainer
    

    Named the icon TextScroller.ico. Place it in the project root directory and change the Build Action to Embeded Resource

Embed Icon

Adding the Control to the Toolbox

Go to View, Toolbox, Right click any place in the Toolbox, Add Tab, I name it MyTextScroller.

Right click MyTextScroller, Choose Items, .NET Framework Components Tab, Browse, find the MyTextScroller.dll, click Ok.

You should see the custom icon next to the control instead of the default icon.

Custom Icon

Comments (12) -

  • Japanese Translation

    6/28/2009 9:32:10 PM |

    Hi,
    I was looking for that solution nearly all day.Can I copy this article on my blog?If so,please mail me,and we can exchange uesful articles in the future.

    Regards,
    Nick

  • Уеб Дизайн

    7/2/2009 4:22:54 AM |

    I can see that you are putting a lot of time and effort into your blog and detailed articles! I am deeply in love with every single piece of information you post here. Reading this post reminds me of my old room mate! He always kept talking about this. I will forward this article to him. Pretty sure he will have a good read. Thanks for sharing!
    Best Regards,
    Chris

  • Voguishchic

    7/22/2009 12:14:50 AM |

    I like reading your post. Keep up the good work.

  • short jokes

    8/27/2009 2:25:55 PM |

    Adding custom toolbox icon for control is helpful in web.But same time it creates some confusions.but after practice its clear now.thanks.

  • tiffany jewelry

    10/7/2009 5:36:04 AM |

    I like your post. I am a new learner of this field. thx for sharing~~

  • regcure review

    11/6/2009 6:50:02 PM |

    this really helps, today i encounter the problems and i donot know how to solve,
    i search and found your blog,

    thanks again

    Best Regards,
    dean

  • giuseppe zanotti website

    12/16/2009 11:10:10 AM |

    Great write up - Thank you for sharing.

  • payday loans

    12/20/2009 10:04:09 PM |

    I wasn't afraid to fail. Something good always comes out of failure.

  • mens fashion

    12/23/2009 9:56:53 AM |

    Great write up - Thank you for sharing.

  • jobs uk

    1/23/2010 4:48:07 PM |

    Thanks mate!I was looking for that solution nearly all day!There are few more questions that I want to ask you.Should I post them as comments?By the way -I love your blog,it is awesome and if you are looking for link exchange with quality job borad in UK,please drop an email-I will be glad to exchange link with your blog
    Regards,
    Chris

  • regime sport

    4/20/2010 6:15:27 AM |

    nice post ;) !

  • robert

    10/18/2010 1:57:47 AM |

    This is great information on how to add icons to your server control

Add comment

Loading