Results 1 to 10 of 10

Thread: [2005] What is the Local setting?

  1. #1

    Thread Starter
    PowerPoster
    Join Date
    Jan 2004
    Location
    Southern California
    Posts
    5,034

    [2005] What is the Local setting?

    I have a program that uses a inhouse developed DLL see highlighted in the first screenshot illustration. It's LOCAL property is set to True. When I try and set it to False...I get the error message as seen in the 2nd illustration. What do I have to do to make this DLL look like the rest of the components where there LOCAL properties are set to False?

    Thanks,
    Last edited by blakemckenna; Oct 9th, 2008 at 10:10 PM.
    Blake

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,222

    Re: [2005] What is the Local setting?

    You seem to have forgotten to attach your screen shots. Are you talking about the Copy Local property of your references?
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  3. #3

    Thread Starter
    PowerPoster
    Join Date
    Jan 2004
    Location
    Southern California
    Posts
    5,034

    Re: [2005] What is the Local setting?

    Yes JMC,

    The Copy Local property...
    Blake

  4. #4
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,222

    Re: [2005] What is the Local setting?

    Ah, you're saying that you get that error message when you run the app with Copy Local set to False, not when you actually try to set it. Now I get it. That's what should happen. Your app can't simply browse the country-side looking for assemblies. The app only knows its own folder and the GAC. If Copy Local is set to False then the referenced assembly must be installed in the GAC.

    That said, it is possible to tell your app to look in specific locations other than those two defaults. I've never done it myself so I don't know the details but you should read this. Step 4 is potentially of special interest.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  5. #5

    Thread Starter
    PowerPoster
    Join Date
    Jan 2004
    Location
    Southern California
    Posts
    5,034

    Re: [2005] What is the Local setting?

    JMC,

    How do I insert the DLL into the GAC? I've never done anythign with that before.

    Thanks,
    Blake

  6. #6
    Frenzied Member MaximilianMayrhofer's Avatar
    Join Date
    Aug 2007
    Location
    IM IN YR LOOP
    Posts
    2,001

    Re: [2005] What is the Local setting?

    You don't want to do that if you're actually distributing your app commercially. The client isn't going to magically have the dll in GAC. Copy local.

  7. #7
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,222

    Re: [2005] What is the Local setting?

    Quote Originally Posted by MaximilianMayrhofer
    The client isn't going to magically have the dll in GAC.
    They won't have it magically, no, but you can install an assembly in the GAC on each system that you install your app on.

    I think the real question here is "why". Why exactly do you not want to copy this assembly to your program folder? The reason that you would install an assembly in the GAC is so that it's available to multiple applications, which is why all those .NET Framework and Crystal Reports assemblies are in the GAC. That way you don't have multiple applications each with their own identical copy of an assembly. Are you intending on having multiple applications access this assembly? If so then the GAC is where it should be. That said, an assembly must have a strong name to be installed in the GAC, so you must sign it.

    To install an assembly to the GAC you can run the gacutil.exe tool from the VS command prompt. If you want an assembly installed to the GAC when you deploy your app then you simply put it in the GAC folder in the File System Editor in your Setup project. Note that ClickOnce applications cannot install to the GAC.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  8. #8

    Thread Starter
    PowerPoster
    Join Date
    Jan 2004
    Location
    Southern California
    Posts
    5,034

    Re: [2005] What is the Local setting?

    This DLL is home grown. It is for my company only. It will not be distributed as a commercial application. I am not sure what the VS Command Line prompt is or how to access it.
    Blake

  9. #9

    Thread Starter
    PowerPoster
    Join Date
    Jan 2004
    Location
    Southern California
    Posts
    5,034

    Re: [2005] What is the Local setting?

    This application is execute from a Terminal Server. However, the application itself resides on another server with all of our other applications. Where does the GAC have to reside. Is it a universal utility or should it reside on every server where applications and DLL's run from?

    Thanks,
    Last edited by blakemckenna; Oct 13th, 2008 at 10:09 AM.
    Blake

  10. #10
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,222

    Re: [2005] What is the Local setting?

    The VS Command prompt would be run from the Start menu. If you want to understand the GAC then I suggest that you read about the GAC.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

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