Application won't launch from network

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Bob L.

    #1

    Application won't launch from network

    Hi everyone,

    I have two small applications I have written that I am trying run from a
    network directory. Both applications have a dependency on another assembly
    (.dll), and I have .NET security wide open. One application is dependent on
    an interop assembly (Interop.IWshRu ntimeLibrary.dl l), and it works fine. The
    other application depends on three assemblies that I have written, and
    although the executable starts successfully, as soon as any one of the
    dependent assemblies attempt to load, I get the following error:

    "Applicatio n has generated an exception that could not be handled."

    Both applications work great when launched from my local drive (Windows
    2000). Any help would be great.

    Thanks,
    Bob L.


  • Prasanna Padmanabhan

    #2
    Re: Application won't launch from network

    Maybe the framework is throwing a SecurityExcepti on
    (System.Securit y.SecurityExcep tion)? I think this is due to the code access
    security feature in .NET.

    "Bob L." <nospam.info1@l ibertyfamily.ne t> wrote in message
    news:OGezH9EaFH A.2212@TK2MSFTN GP14.phx.gbl...[color=blue]
    > Hi everyone,
    >
    > I have two small applications I have written that I am trying run from a
    > network directory. Both applications have a dependency on another assembly
    > (.dll), and I have .NET security wide open. One application is dependent[/color]
    on[color=blue]
    > an interop assembly (Interop.IWshRu ntimeLibrary.dl l), and it works fine.[/color]
    The[color=blue]
    > other application depends on three assemblies that I have written, and
    > although the executable starts successfully, as soon as any one of the
    > dependent assemblies attempt to load, I get the following error:
    >
    > "Applicatio n has generated an exception that could not be handled."
    >
    > Both applications work great when launched from my local drive (Windows
    > 2000). Any help would be great.
    >
    > Thanks,
    > Bob L.
    >
    >[/color]


    Comment

    • Bob L.

      #3
      Re: Application won't launch from network

      I'm a little dubious of security being the culprit, for three reasons:

      1) I have opened up absolutely every security option that .NET allows.
      2) One app works and the other does not. If security was an issue, I would
      think that both apps would fail.
      3) The error message says that it is an exception that can not be handled,
      while security exceptions are able to be handled

      "Prasanna Padmanabhan" <prasannap@citr ixnospamtolerat ed.com> wrote in
      message news:ey9aVEFaFH A.3536@TK2MSFTN GP10.phx.gbl...[color=blue]
      > Maybe the framework is throwing a SecurityExcepti on
      > (System.Securit y.SecurityExcep tion)? I think this is due to the code[/color]
      access[color=blue]
      > security feature in .NET.
      >
      > "Bob L." <nospam.info1@l ibertyfamily.ne t> wrote in message
      > news:OGezH9EaFH A.2212@TK2MSFTN GP14.phx.gbl...[color=green]
      > > Hi everyone,
      > >
      > > I have two small applications I have written that I am trying run from a
      > > network directory. Both applications have a dependency on another[/color][/color]
      assembly[color=blue][color=green]
      > > (.dll), and I have .NET security wide open. One application is dependent[/color]
      > on[color=green]
      > > an interop assembly (Interop.IWshRu ntimeLibrary.dl l), and it works fine.[/color]
      > The[color=green]
      > > other application depends on three assemblies that I have written, and
      > > although the executable starts successfully, as soon as any one of the
      > > dependent assemblies attempt to load, I get the following error:
      > >
      > > "Applicatio n has generated an exception that could not be handled."
      > >
      > > Both applications work great when launched from my local drive (Windows
      > > 2000). Any help would be great.
      > >
      > > Thanks,
      > > Bob L.
      > >
      > >[/color]
      >
      >[/color]


      Comment

      • Nick Malik [Microsoft]

        #4
        Re: Application won't launch from network

        This is most often caused because the system cannot find the dll that it
        expects to call.

        When you are running your app from the network, are all of the dependent
        DLLs either in the GAC or in the directory where the executable are located,
        or do some of your dependencies live on the hard drive?

        --
        --- Nick Malik [Microsoft]
        MCSD, CFPS, Certified Scrummaster
        http://blogs.msdn.com/nickmalik

        Disclaimer: Opinions expressed in this forum are my own, and not
        representative of my employer.
        I do not answer questions on behalf of my employer. I'm just a
        programmer helping programmers.
        --
        "Bob L." <nospam.info1@l ibertyfamily.ne t> wrote in message
        news:OGezH9EaFH A.2212@TK2MSFTN GP14.phx.gbl...[color=blue]
        > Hi everyone,
        >
        > I have two small applications I have written that I am trying run from a
        > network directory. Both applications have a dependency on another assembly
        > (.dll), and I have .NET security wide open. One application is dependent
        > on
        > an interop assembly (Interop.IWshRu ntimeLibrary.dl l), and it works fine.
        > The
        > other application depends on three assemblies that I have written, and
        > although the executable starts successfully, as soon as any one of the
        > dependent assemblies attempt to load, I get the following error:
        >
        > "Applicatio n has generated an exception that could not be handled."
        >
        > Both applications work great when launched from my local drive (Windows
        > 2000). Any help would be great.
        >
        > Thanks,
        > Bob L.
        >
        >[/color]


        Comment

        • AlexS

          #5
          Re: Application won't launch from network

          I think you have security issue there. Check if >net allows you to launch
          from your network location

          HTH
          Alex

          "Nick Malik [Microsoft]" <nickmalik@hotm ail.nospam.com> wrote in message
          news:ZIudnQXoRu AKbzzfRVn-gA@comcast.com. ..[color=blue]
          > This is most often caused because the system cannot find the dll that it
          > expects to call.
          >
          > When you are running your app from the network, are all of the dependent
          > DLLs either in the GAC or in the directory where the executable are[/color]
          located,[color=blue]
          > or do some of your dependencies live on the hard drive?
          >
          > --
          > --- Nick Malik [Microsoft]
          > MCSD, CFPS, Certified Scrummaster
          > http://blogs.msdn.com/nickmalik
          >
          > Disclaimer: Opinions expressed in this forum are my own, and not
          > representative of my employer.
          > I do not answer questions on behalf of my employer. I'm just a
          > programmer helping programmers.
          > --
          > "Bob L." <nospam.info1@l ibertyfamily.ne t> wrote in message
          > news:OGezH9EaFH A.2212@TK2MSFTN GP14.phx.gbl...[color=green]
          > > Hi everyone,
          > >
          > > I have two small applications I have written that I am trying run from a
          > > network directory. Both applications have a dependency on another[/color][/color]
          assembly[color=blue][color=green]
          > > (.dll), and I have .NET security wide open. One application is dependent
          > > on
          > > an interop assembly (Interop.IWshRu ntimeLibrary.dl l), and it works fine.
          > > The
          > > other application depends on three assemblies that I have written, and
          > > although the executable starts successfully, as soon as any one of the
          > > dependent assemblies attempt to load, I get the following error:
          > >
          > > "Applicatio n has generated an exception that could not be handled."
          > >
          > > Both applications work great when launched from my local drive (Windows
          > > 2000). Any help would be great.
          > >
          > > Thanks,
          > > Bob L.
          > >
          > >[/color]
          >
          >[/color]


          Comment

          • Bob L.

            #6
            Re: Application won't launch from network

            Everything is in the same folder (no GAC), but I did find a clue - If I
            don't use strong names, everything works great off the network. As soon as I
            recompile using strong names, it blows up with a security error, even though
            my security settings are set to "Grant assemblies unrestricted access to all
            security permissions". I am testing the URL membership condition using the
            syntax file://server/folder/*.

            This problem is extremely easy to reproduce by just creating an executable
            with one button that makes a call to a DLL. If the DLL has a strong name,
            it's toast.

            - Bob

            "Nick Malik [Microsoft]" <nickmalik@hotm ail.nospam.com> wrote in message
            news:ZIudnQXoRu AKbzzfRVn-gA@comcast.com. ..[color=blue]
            > This is most often caused because the system cannot find the dll that it
            > expects to call.
            >
            > When you are running your app from the network, are all of the dependent
            > DLLs either in the GAC or in the directory where the executable are[/color]
            located,[color=blue]
            > or do some of your dependencies live on the hard drive?
            >
            > --
            > --- Nick Malik [Microsoft]
            > MCSD, CFPS, Certified Scrummaster
            > http://blogs.msdn.com/nickmalik
            >
            > Disclaimer: Opinions expressed in this forum are my own, and not
            > representative of my employer.
            > I do not answer questions on behalf of my employer. I'm just a
            > programmer helping programmers.
            > --
            > "Bob L." <nospam.info1@l ibertyfamily.ne t> wrote in message
            > news:OGezH9EaFH A.2212@TK2MSFTN GP14.phx.gbl...[color=green]
            > > Hi everyone,
            > >
            > > I have two small applications I have written that I am trying run from a
            > > network directory. Both applications have a dependency on another[/color][/color]
            assembly[color=blue][color=green]
            > > (.dll), and I have .NET security wide open. One application is dependent
            > > on
            > > an interop assembly (Interop.IWshRu ntimeLibrary.dl l), and it works fine.
            > > The
            > > other application depends on three assemblies that I have written, and
            > > although the executable starts successfully, as soon as any one of the
            > > dependent assemblies attempt to load, I get the following error:
            > >
            > > "Applicatio n has generated an exception that could not be handled."
            > >
            > > Both applications work great when launched from my local drive (Windows
            > > 2000). Any help would be great.
            > >
            > > Thanks,
            > > Bob L.
            > >
            > >[/color]
            >
            >[/color]


            Comment

            Working...