So far I have not had problems with usercontrols that do not appear in the toolbar. Create a project and it just appears. Then it’s not working today. After the search, I went through the next, but still not joy.
- Tools> Options> Windows Forms Designer> General: AutoToolboxPopulate
- Tools> Options> Text editor> XMAL> Miscellaneous: AutoToolboxPopulate
- Reset VS default settings
So, after several hours of turmoil, trying to get it to work without success, I created a new Windows WPF project that accepted the default name and added usercontrol. Built the project, and the user control appeared, as always.
Then I thought something might be wrong with my project or wpf window file. We deleted the project, created a new one and added a new control. Built a project, but it didn’t work.
The only thing I did differently was to choose a name for the project, in which I included a space in the name of “WPF Application”.
Deleted the project again and created a new one, again called "WPFApplication" without a space, and added a user control. Built, and the user control appeared.
If you want usercontrols to automatically appear in the toolbar during assembly, do not use spaces in the project name. Hope this post saves someone else a ton of wasted time.
John Petrak Dec 05 2018-10-12T00: 00Z
source share