Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: Visual-Studio C#4.0 , +
Hi ,
 

I'm writing a user control for my c# application using VS2012 . When I'm adding another windows forms application project to same solution which I created the user control , the user control is showing up on the toolbox window and user control is working fine.But when I create individual project and add reference to .dll file I could not load the user control to toolbox.When I try to add the following message is showing :
 
"There are no component in <.dll path> that can be placed on the toolbox".
 
but actually there is a user control inside that dll .
 

What could be the possible problem ? please help ...
Posted 29-Jun-13 1:11am
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

I've solved it at last Big Grin | :-D
 
The problem was my dll file haven't a strong name.
 
I followed these links to solve this problem
 
First I created a new user control
 
http://msdn.microsoft.com/en-us/library/9yxtkx75(v=vs.85).aspx[^]
 
Then I looked into the following link to add my control to toolbox window
 
http://msdn.microsoft.com/en-us/library/9yxtkx75(v=vs.85).aspx[^]
 
From that link I learned that I should Install my control assembly to the Global Assembly Cache
 
http://msdn.microsoft.com/en-us/library/dkkx7f79(v=vs.110).aspx
 
To add to global assembly cache I need to assign a strong name to the dll
http://msdn.microsoft.com/en-us/library/h4fa028b(v=vs.100).aspx[^]
 

I did that and solved my problem ...
  Permalink  
v2
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Add the dll, reference it
Compile the project
Save the solution and restart visual studio
  Permalink  
Comments
Jackson K T at 1-Jul-13 0:51am
   
I tried this before posting this question.Not working :( ...

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 475
1 Maciej Los 349
2 Richard MacCutchan 220
3 BillWoodruff 219
4 Mathew Soji 160
0 OriginalGriff 8,759
1 Sergey Alexandrovich Kryukov 7,407
2 DamithSL 5,639
3 Maciej Los 5,269
4 Manas Bhardwaj 4,986


Advertise | Privacy | Mobile
Web01 | 2.8.1411028.1 | Last Updated 2 Jul 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100