BC30002: Type 'NameClass' not defined

I've struggled a few minutes too long to resolve this problem.
I writed a new class with some type inside, added by a new Namespace.
I added the relative reference on the project.
The solution compiles correctly, but at the site's launch on localhost, I obtained the following error

 BC30002: Type 'NameClass' not defined 


Check if has been added the dll relative to the reference added and/or in the web.config has been added the relative assembly reference.
If not, the solution is to manually add the reference in the following manner
(in my case System.Security)

 <compilation debug="true" strict="false" explicit="true" targetFramework="4.0"> 
     <add assembly="System.Security, Version=, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/> 

To find the exact string to write in the web.config, search in the machine.config that shows all packages already installed on your PC.


No comments:

Post a Comment