Re: Namespace Question

From: Tiraman (tiraman_at_netvision.net.il)
Date: 04/07/04


Date: Wed, 7 Apr 2004 19:55:58 +0200

Hi Peter ,

i read the articles that u sent me and they were good :-)

Now that i know that the ASP.NET check in 3 places i can choose where to put
my dll's which is good .

For the copylocal property ,
i saw that when i changed it to true my dll was copied to the bin folder but
the question is what if i m changing the original Dll
does it will copy the new version again ?

let me answer that :-) i did a little change in the dll and nothing happen
and only after i set the copylocal property to false and than to true
the new change was done .
do u know if there is a way to use the copylocal property without coping the
dll to the bin folder each time ?
do you recommend to use this property ?

For the Reference Path Issue ,
in the article that you sent me
(http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cscon/html
/vcurfcbuildpropertypage.asp)
they wrote that
When the project system finds an assembly reference, it will try to resolve
the reference by looking in the following locations, in the following order
1. project directory
2. Look for assemblies in directories specified with the Reference Path
property

and so on ...
but some how it didn't work for me even when i added the path for my dlls
(C:\MyDlls\) , how come ?

if i understand you right you preferred to use the GAC ?

 tried to use the GAC but the process to convert dll to be strong name bcz
the GAC require is very long but in the end i success with the long process
but
when i moved the dll out of the project directory and then i drag the dll in
to the C:\WINDOWS\assembly folder
and i tried to use the dll i got the not defined error :-(

any ideas ?

once again ,

10x :-)

""Peter Huang"" <v-phuang@online.microsoft.com> wrote in message
news:QFvtqVGHEHA.3244@cpmsftngxa06.phx.gbl...
> Hi Tiraman,
>
> First of all, I would like to confirm my understanding of your issue.
> From your description, I understand that you wants to put an assembly(dll)
> into a directory which will be shared by many applications.
> Have I fully understood you? If there is anything I misunderstood, please
> feel free to let me know.
>
> I suggest you put the asssembly into GAC.
>
>
> For ASP.NET it will check three places to locate the assembly.
> 1. GAC
> 2. the bin directory of the application
> 3. the codebase element specified in the web.config.
>
> For detailed information.
>
> How the Runtime Locates Assemblies
>
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dncfhowto/h
> tml/HOWTOGAC.asp
>
> From my experience I think the Reference Path properties is not used on
> runtime.
>
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cscon/html/
> vcurfcbuildpropertypage.asp
>
> From your description, when you place the assembly into c:\MyDlls\ , the
> project will work.
> I think this may caused by the Test.dll has been copied into the bin
folder
> of the application. You may check the bin folder for confirm. Also you can
> check the Copy Local property by right click on the reference under the
> Solution explorer/References tree and select properties, if the property
is
> true, the test.dll will be copied to the bin folder of the application.
>
> For the default Namespace issue, I think you can check the Root namaspace
> section by right click the project in the solution explorer and select
> properties, in the following property page, and drill down to Common
> Properties/General -->Root namaspace. By default the Root namaspace will
be
> the project name.
> e.g.
> Root namaspace is Consoleapplication1
> and you define a namespace TestNameSpace in the file.
> The the absolute namespace will be Consoleapplication1.TestNameSpace
>
> Please apply my suggestion above and let me know if it helps resolve your
> problem.
>
>
> Best regards,
>
> Peter Huang
> Microsoft Online Partner Support
>
> Get Secure! - www.microsoft.com/security
> This posting is provided "AS IS" with no warranties, and confers no
rights.
>



Relevant Pages

  • Re: Assembly resource file not found for non-admin users!
    ... there is no difference between GAC and BIN! ... > if my DLLs are copied into the bin folder instead-of the GAC, ... >> language resource file is not loaded. ... >> if an administrator load the page, then the DLL is found and loaded into ...
    (microsoft.public.dotnet.framework.aspnet)
  • RE: Webpart deployment question
    ... Yes there is no reason to have the dll in both the gac and the bin folders, ... into the GAC as opposed to the bin folder. ... "Henke" wrote: ...
    (microsoft.public.sharepoint.portalserver.development)
  • Re: Adding a dll to an ASP.NET application
    ... you deploy, you need to include the bin folder, as this is the only ... place asp.net looks beside the gac and the .net bin folder ... adll.refreshfile that points to the original copy of the dll. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: vs doesnt recognized newly added methods in references
    ... new .dll get properly registered into the GAC? ... the reference path to the newly compiled dll ...
    (microsoft.public.dotnet.framework.aspnet)
  • Managing files in bin folder
    ... bin folder starts getting pretty crowded. ... I want to postpone any DLL ... registration to GAC until I will be very sure that the core API is not going ...
    (microsoft.public.dotnet.framework.aspnet)

Loading