Sign in to follow this  
Tct

C# Custom Control doesn't appear in toolbox

Recommended Posts

I can't seem to find an answer to an easy problem, and begining to wonder maybe my Visual Studio has a bug. Well anyways, the main idea is to create a custom control and add it to form through form designer, but the my custom control just won't show up in toolbox, no matter how I try. There are two way how to create custom control: 1. create a project Windows Forms Control Library, compile it to dll, and add it as a reference into a new Windows Forms project then it will appear in the toolbox (but this is not what I want) 2. Create custom control class inside Windows Forms project and use it... In other words my custom control is in the same project as my main project I am trying to create my custom control with that second method, but I have no idea how to make that my custom control would appear in the toolbox (cause I am not adding any reference), only then I will be able to drag it and use on my Windows Form using Form Designer... I've tried dragging custom control class on the toolbox and a little '+' appears, indicating that it's legal, but no control appear there, so can't add my custom control through form designer, of course I could edit the code and add a custom control manually, but it feels wrong. So any ideas? Thank you [Edited by - jpetrie on February 10, 2010 12:04:49 PM]

Share this post


Link to post
Share on other sites
Rebuilding your project should be sufficient. Ensure that AutoToolboxPopulate is set to True in Tools→Options→Windows Form Designer (you may need to tick "Show all settings" first).

Share this post


Link to post
Share on other sites
benryves> You're my Hero!!! It actually works, there are small glitches, but it works.

Thanks!!!

That option was really off, so turning it on solved my problem.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this