Results 1 to 4 of 4

Thread: How to add a DLL to the GAC?

  1. #1

    Thread Starter
    yay gay PT Exorcist's Avatar
    Join Date
    Apr 2002
    Location
    . . . my reason of shame
    Posts
    2,729

    How to add a DLL to the GAC?

    I have 2 DLL's (which is not mine). One is from version1 and other is version2. I installed DLL 1 and everything went alright. It installed it also in the GAC. Now I tried replacing version2 with version1 but it just acts like I was using version1 DLL. I know this has something to do with the GAC. What have I to do? Do I really have to use the GAC? I tried deleting it but it doesnt allow I dont know why..

    I also tried to add the new DLL to the GAC but it says it's not a strong assembly (but i've tried doing "sn -v dllname.dll" and it said it was a valid assembly)

    Any help is greatly appreciated
    \m/\m/

  2. #2
    Fanatic Member VBCrazyCoder's Avatar
    Join Date
    Apr 2003
    Posts
    681
    You can access the GAC by Start/settings/control panel/ admin tools/ 1.1 configuration - assembly cache link.

    Are you using auto-deployment - because there is a separate cache for those dlls that you may need to clear.

  3. #3
    Sleep mode
    Join Date
    Aug 2002
    Location
    RUH
    Posts
    8,083
    MSDN Help .
    ms-help://MS.VSCC.2003/MS.MSDNQTR.2003APR.1033/cpguide/html/cpconinstallingassemblyintoglobalassemblycache.htm

  4. #4

    Thread Starter
    yay gay PT Exorcist's Avatar
    Join Date
    Apr 2002
    Location
    . . . my reason of shame
    Posts
    2,729
    hmm solved it.

    The problem was the DLL already had a key assigned to it in code and then when i tried to give it another he wouldn't know what to choose. Anyways here's how i compiled it:

    Code:
    sn -k "key.snk"
    ilasm "my_il_file.il" /DLL /KEY="key.snk"
    \m/\m/

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width