Shared User Control - with Codebehind

  • Thread starter Thread starter Marcos MOS
  • Start date Start date
M

Marcos MOS

Hi there!

I'm following this article
(http://www.codeproject.com/aspnet/ctrlreuse.asp -> "Share your user control
across multiple web applications".
It explains how to share user control with codebehind.

So, I have 2 projects: The first is my UserControl's project and the other
the Consumer's project.
I have put the assembly in GAC but I'm still getting this error at the
consumer: Could not load type 'SharedUserControl.CabecalhoPadrao'

In short, my consumer's project can achieve the usercontrol (in deeper
virtual directory) but that says can't "see" the class (CabecalhoPadrao)...

Any Ideas?

thanks so mutch
Marcos
 
Yes, I did.

If I cut out the Codebehind and Inherits tags and put the block code in aspx
file ... That error disappear...

thanks
Marcos
 
Hi!

Now It is working ok!
But I have to put that line <add assembly="WebProjectShared,
Version=1.0.1.2, Culture=neutral, PublicKeyToken=e76881568d417308"/>
into the machine.config, ok?
But Could you teach me How version issue works? I mean, if I rebuild my
assembly with the same version the Consumer project doen't see the changes,
right? Is there any way?

thanks
Marcos
 
Back
Top