Putting a user control into the Global Assembly cache

X

Xin Li

I am writing a database searching system that will be shared across
about 30 or so websites. A while back I asked how I can share the
business objects among the 30 websites, and was introduced to the
global assembly cache.

Now I need to do the same for a user control that I'm developing.
It's the search page for the database. I'd like to be able to put it
on any page. How would I do that? As a matter of fact, how do I go
about compiling all of the business objects and the user control into
a DLL using the VC# compiler? Visual studio does so much for me that
I think I'm getting spoiled and forgetting the basics.

Thanks so much for putting up with a newbie.

Xin Li
 
J

John Saunders

Xin Li said:
I am writing a database searching system that will be shared across
about 30 or so websites. A while back I asked how I can share the
business objects among the 30 websites, and was introduced to the
global assembly cache.

Now I need to do the same for a user control that I'm developing.
It's the search page for the database. I'd like to be able to put it
on any page. How would I do that? As a matter of fact, how do I go
about compiling all of the business objects and the user control into
a DLL using the VC# compiler? Visual studio does so much for me that
I think I'm getting spoiled and forgetting the basics.

User controls aren't meant to be shared, really. You might want to create a
custom control with the functionality of the user control. The assembly
containing the custom control can then be placed in the GAC.
 
C

Craig Deelsnyder

I am writing a database searching system that will be shared across
about 30 or so websites. A while back I asked how I can share the
business objects among the 30 websites, and was introduced to the
global assembly cache.

Now I need to do the same for a user control that I'm developing.
It's the search page for the database. I'd like to be able to put it
on any page. How would I do that? As a matter of fact, how do I go
about compiling all of the business objects and the user control into
a DLL using the VC# compiler? Visual studio does so much for me that
I think I'm getting spoiled and forgetting the basics.

Thanks so much for putting up with a newbie.

Xin Li

Well, you can't if it has an .ascx portion (visual portion) to it. You'd
need to only have it as a class (no codefront), e.g. spit out the HTML in
render, etc. Or convert it to a composite or custom control class. Then
you can compile it into a dll...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,578
Members
45,052
Latest member
LucyCarper

Latest Threads

Top