473,395 Members | 1,637 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

When do I use shared assemblies that is using GAC

Hello!

Can somebody tell me exactly when do I use GAC where shared assembly dll is
stored.

//Tony
Sep 14 '06 #1
7 3593
Define "use". The CLR is in the GAC, so any time you're using a platform
class, you're using the GAC.

Shared assemblies can be stored anywhere. Many of them are stored in
subfolders under the \Windows\assembly folder, folders which are invisible,
even if you allow hidden and system files to be viewed. The only time I've
seen them is when uninstalling the Framework.

--
HTH,

Kevin Spencer
Microsoft MVP
Chicken Salad Surgery

What You Seek Is What You Get.

"tony" <jo*****************@telia.comwrote in message
news:%2*****************@TK2MSFTNGP03.phx.gbl...
Hello!

Can somebody tell me exactly when do I use GAC where shared assembly dll
is
stored.

//Tony


Sep 14 '06 #2
Hello!

I mean when exactly is adviseable to put assembly dll in the GAC.

//Tony

"Kevin Spencer" <uc*@ftc.govskrev i meddelandet
news:eJ**************@TK2MSFTNGP04.phx.gbl...
Define "use". The CLR is in the GAC, so any time you're using a platform
class, you're using the GAC.

Shared assemblies can be stored anywhere. Many of them are stored in
subfolders under the \Windows\assembly folder, folders which are
invisible,
even if you allow hidden and system files to be viewed. The only time I've
seen them is when uninstalling the Framework.

--
HTH,

Kevin Spencer
Microsoft MVP
Chicken Salad Surgery

What You Seek Is What You Get.

"tony" <jo*****************@telia.comwrote in message
news:%2*****************@TK2MSFTNGP03.phx.gbl...
Hello!

Can somebody tell me exactly when do I use GAC where shared assembly dll
is
stored.

//Tony


Sep 14 '06 #3
I think the recommended way is "unless you absolutely needed to share
that assembly (like .Net framework assembly) across a lot of
applications. you really shouldn't do that..

A good way to share your assembly is :

Under :
Program Files\Your Application\

YourFirstApplication.exe
YourSecondApplication.exe

Then you create an folder called SharedAssembly under the folder (
Program Files\Your Application\SharedAssembly) and put your all the
shared assemblies there.

HTH..
tony wrote:
Hello!

I mean when exactly is adviseable to put assembly dll in the GAC.

//Tony

"Kevin Spencer" <uc*@ftc.govskrev i meddelandet
news:eJ**************@TK2MSFTNGP04.phx.gbl...
>Define "use". The CLR is in the GAC, so any time you're using a platform
class, you're using the GAC.

Shared assemblies can be stored anywhere. Many of them are stored in
subfolders under the \Windows\assembly folder, folders which are
invisible,
>even if you allow hidden and system files to be viewed. The only time I've
seen them is when uninstalling the Framework.

--
HTH,

Kevin Spencer
Microsoft MVP
Chicken Salad Surgery

What You Seek Is What You Get.

"tony" <jo*****************@telia.comwrote in message
news:%2*****************@TK2MSFTNGP03.phx.gbl.. .
>>Hello!

Can somebody tell me exactly when do I use GAC where shared assembly dll
is
stored.

//Tony


Sep 14 '06 #4
Generally, it is not adviseable to do so.

--
HTH,

Kevin Spencer
Microsoft MVP
Chicken Salad Surgery

What You Seek Is What You Get.

"tony" <jo*****************@telia.comwrote in message
news:eB*************@TK2MSFTNGP06.phx.gbl...
Hello!

I mean when exactly is adviseable to put assembly dll in the GAC.

//Tony

"Kevin Spencer" <uc*@ftc.govskrev i meddelandet
news:eJ**************@TK2MSFTNGP04.phx.gbl...
>Define "use". The CLR is in the GAC, so any time you're using a platform
class, you're using the GAC.

Shared assemblies can be stored anywhere. Many of them are stored in
subfolders under the \Windows\assembly folder, folders which are
invisible,
>even if you allow hidden and system files to be viewed. The only time
I've
seen them is when uninstalling the Framework.

--
HTH,

Kevin Spencer
Microsoft MVP
Chicken Salad Surgery

What You Seek Is What You Get.

"tony" <jo*****************@telia.comwrote in message
news:%2*****************@TK2MSFTNGP03.phx.gbl.. .
Hello!

Can somebody tell me exactly when do I use GAC where shared assembly
dll
is
stored.

//Tony




Sep 14 '06 #5
You should put your assembly in GAC ie. you should make your assemblies
shared only when if more than one applications need to use it. Otherwise, it
is better to have the assemblies as private only.

--
Nand Kishore Gupta
"tony" wrote:
Hello!

Can somebody tell me exactly when do I use GAC where shared assembly dll is
stored.

//Tony
Sep 15 '06 #6
I wonder if the shared assemblies must be under "Program Files" folder.
Could it be in different folder ?

Thanks,
Eric.-
"Jianwei Sun" wrote:
I think the recommended way is "unless you absolutely needed to share
that assembly (like .Net framework assembly) across a lot of
applications. you really shouldn't do that..

A good way to share your assembly is :

Under :
Program Files\Your Application\

YourFirstApplication.exe
YourSecondApplication.exe

Then you create an folder called SharedAssembly under the folder (
Program Files\Your Application\SharedAssembly) and put your all the
shared assemblies there.

HTH..
tony wrote:
Hello!

I mean when exactly is adviseable to put assembly dll in the GAC.

//Tony

"Kevin Spencer" <uc*@ftc.govskrev i meddelandet
news:eJ**************@TK2MSFTNGP04.phx.gbl...
Define "use". The CLR is in the GAC, so any time you're using a platform
class, you're using the GAC.

Shared assemblies can be stored anywhere. Many of them are stored in
subfolders under the \Windows\assembly folder, folders which are
invisible,
even if you allow hidden and system files to be viewed. The only time I've
seen them is when uninstalling the Framework.

--
HTH,

Kevin Spencer
Microsoft MVP
Chicken Salad Surgery

What You Seek Is What You Get.

"tony" <jo*****************@telia.comwrote in message
news:%2*****************@TK2MSFTNGP03.phx.gbl...
Hello!

Can somebody tell me exactly when do I use GAC where shared assembly dll
is
stored.

//Tony
Dec 13 '06 #7

ericms wrote:
I wonder if the shared assemblies must be under "Program Files" folder.
Could it be in different folder ?
We just copy the assembly into the same folder as the application
(.exe) file. If there are several applications in the same folder then
they can share DLLs.

There is no requirement that they be under "Program Files" unless that
is where you keep your .exes. You can look up articles on exactly how
the CLR searches for assemblies:

http://msdn2.microsoft.com/en-us/library/yx7xezcf.aspx

We do not use the GAC. The GAC is _necessary_ only if you need to
support side-by-side versioning. That is, only if you need multiple
versions of the same assembly loaded on your system at one time. Even
then, you could do this manually by simply keeping your applications in
separate folders and deploying the correct version of the DLL to the
relevant folder.

The GAC is there for commercial software developers who want control
over versioning. For those of us who do software development for
strictly in-house consumption, it's optional.

Dec 13 '06 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Dan | last post by:
Here's a scenario I'd like to discuss in order to setup my VS.NET IDE properly and be able to prepare a distribution: a) I have a windows forms C# app using 3 shared assemblies I developed to...
0
by: RadekP | last post by:
Hi Gurus .. I would really appreciate some insights for the problem that bugs me for quite some time. I keep my custom controls in their own shared (private/public key signed) assembly. I need...
9
by: Invalidlastname | last post by:
Hi, We developed some assemblies which use EnterpriseServices queued components. In order to use EnterpriseServices, these assemblies need to be installed into GAC. I used the pre-build and...
3
by: Sam-I-Am | last post by:
Hi all I have a common shared assembly in intalled in the GAC: myco.myprod.common.dll I have set a reference to this assembly in a asp.net web application. I have config sections in my...
2
by: Sky | last post by:
Hello: I'm trying to make sense of snk files, when to use, under what conditions to regenerate new ones,...can someone take a look if these statemes make sense? And then the final questions at the...
94
by: Samuel R. Neff | last post by:
When is it appropriate to use "volatile" keyword? The docs simply state: " The volatile modifier is usually used for a field that is accessed by multiple threads without using the lock...
2
by: =?ISO-8859-1?B?RulybmFz?= | last post by:
Hey all, I have a URGENT problem and I hope someone could help me... scenery: I have a windows app, coded using C# (framework 1.1 - VS2003)... The exe and dlls of the app is are stored in a...
3
by: Tony Johansson | last post by:
Hello! I just want to check with you if .NET assemblies consist of only shared assemblies ? It must be shared assemblies because you never copies these assemblies to the folder where your...
16
by: MA | last post by:
Hi, We have added a shared assembly in GAC so that our multiple solutions can use use it. We use the publisher policy to controls the different versions of the assembly. This shared assembly...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.