True or False

  • Thread starter Thread starter Michael.Suarez
  • Start date Start date
M

Michael.Suarez

In order for a .Net assembly to be shared amongst several applications,
1 of the following MUST be true:
a) The assembly has to be registered in the GAC.
b) The assembly has to be in the system32 folder AND in the registry.
OR c) All of the executable files accessing this assembly must be in
the same root folder, along with the assembly.

I believe the above statement is true, in that these are the only 3
cases a shared assembly can exist.

I am HOPING I am wrong, and that there are more cases.

If anyone can either confirm that i am right, or prove that i am wrong
by providing examples, I would be greatly appreciative.

Thanks,
Mike
 
In order for a .Net assembly to be shared amongst several applications,
1 of the following MUST be true:
a) The assembly has to be registered in the GAC.

This is one possibility and will create a globally accessible assembly.
b) The assembly has to be in the system32 folder AND in the registry.

This is not quite fully baked. I assume you are talking about either a) COM
components or b) .NET Components set up with COM wrappers. If so, you
register the components (or wrappers) and they become globally available.
OR c) All of the executable files accessing this assembly must be in
the same root folder, along with the assembly.

This is one possibility, but not a requirement. The easiest for side-by-side
is placing everything into the bin folder (web apps) or alongside the
executable(s).

A few notes:

1. You can set up a shared folder and set up each app to use that folder.
This can be done by a simple configuration file change to point to the
directory. It is even possible, though not advised, to do this at the machine
config level, creating your own form of GAC. Look at the help files on config
to set up in this manner.

2. You can use Enterprise Services and put the "applications" in COM+. This
is not advised unless you are using DCOM for your distributed connections,
which is not the .NET way of doing things. It is possible that this is a good
thing if you are reusing these "services" (.NET name) or "applications" (COM+
name) from both COM and .NET.

3. You can create web services and use references to these services. This is
very 2.0 oriented, but it works in 1.x, as well.

4. You can set up windows services with proper interfaces.

The last two are best for reuse across multiple apps, but also require you
start thinking in terms of messages and not function calls.

--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA

***************************
Think Outside the Box!
***************************
 
"1. You can set up a shared folder and set up each app to use that
folder.
This can be done by a simple configuration file change to point to the
directory. It is even possible, though not advised, to do this at the
machine
config level, creating your own form of GAC. Look at the help files on
config
to set up in this manner. "

THANK YOU!!!!!

This is the answer I have been looking for!
I'll check out the help files on config, as you suggest.

Though, why is it not advisable?

Thanks again.

-Mike
 
Back
Top