Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. Managed C++/CLI
  4. System.IO.FileLoadException with /clr

System.IO.FileLoadException with /clr

Scheduled Pinned Locked Moved Managed C++/CLI
announcementc++dotnetdebugginghelp
5 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    Mary Chennai
    wrote on last edited by
    #1

    Hi, I am currently converting my VC++ project to mixed mode by enabling /clr. But i am getting a 'System.IO.FileLoadException' in DeBug and not in Release mode, with the following information: An unhandled exception of type 'System.IO.FileLoadException' occurred in Unknown Module. Additional information: Could not load file or assembly 'MyProj, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Could not find or load a type. (Exception from HRESULT: 0x80131522) Please could someone help me to resolve this.... Regards RMR

    L J F 3 Replies Last reply
    0
    • M Mary Chennai

      Hi, I am currently converting my VC++ project to mixed mode by enabling /clr. But i am getting a 'System.IO.FileLoadException' in DeBug and not in Release mode, with the following information: An unhandled exception of type 'System.IO.FileLoadException' occurred in Unknown Module. Additional information: Could not load file or assembly 'MyProj, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Could not find or load a type. (Exception from HRESULT: 0x80131522) Please could someone help me to resolve this.... Regards RMR

      L Offline
      L Offline
      led mike
      wrote on last edited by
      #2

      Rinnu Mary wrote:

      in DeBug and not in Release mode,

      Difficult to do anything but guess based on the information you provided. Project settings are likely missing something for the Debug version of the settings. Maybe the reference to this 'MyProj' assembly?

      led mike

      1 Reply Last reply
      0
      • M Mary Chennai

        Hi, I am currently converting my VC++ project to mixed mode by enabling /clr. But i am getting a 'System.IO.FileLoadException' in DeBug and not in Release mode, with the following information: An unhandled exception of type 'System.IO.FileLoadException' occurred in Unknown Module. Additional information: Could not load file or assembly 'MyProj, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Could not find or load a type. (Exception from HRESULT: 0x80131522) Please could someone help me to resolve this.... Regards RMR

        J Offline
        J Offline
        Jeffrey Walton
        wrote on last edited by
        #3

        Hi Rinnu,

        Rinnu Mary wrote:

        An unhandled exception of type 'System.IO.FileLoadException' occurred in Unknown Module.

        Copy the file you are trying to open into either PWD or the \Debug folder (I can never remember which...).

        Rinnu Mary wrote:

        Additional information: Could not load file or assembly 'MyProj, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Could not find or load a type. (Exception from HRESULT: 0x80131522)

        I believe you are getting this because you are not catching the exception. Jeff

        J 1 Reply Last reply
        0
        • J Jeffrey Walton

          Hi Rinnu,

          Rinnu Mary wrote:

          An unhandled exception of type 'System.IO.FileLoadException' occurred in Unknown Module.

          Copy the file you are trying to open into either PWD or the \Debug folder (I can never remember which...).

          Rinnu Mary wrote:

          Additional information: Could not load file or assembly 'MyProj, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Could not find or load a type. (Exception from HRESULT: 0x80131522)

          I believe you are getting this because you are not catching the exception. Jeff

          J Offline
          J Offline
          Jeffrey Walton
          wrote on last edited by
          #4

          Hi Rinnu, I was not paying close enough attention to details... I thought I read FileNotFound exception. Jeff

          1 Reply Last reply
          0
          • M Mary Chennai

            Hi, I am currently converting my VC++ project to mixed mode by enabling /clr. But i am getting a 'System.IO.FileLoadException' in DeBug and not in Release mode, with the following information: An unhandled exception of type 'System.IO.FileLoadException' occurred in Unknown Module. Additional information: Could not load file or assembly 'MyProj, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Could not find or load a type. (Exception from HRESULT: 0x80131522) Please could someone help me to resolve this.... Regards RMR

            F Offline
            F Offline
            fredsparkle
            wrote on last edited by
            #5

            We ran into something that might have a bearing on this. The problem ran into was that we were getting a new library from a third party. The developer installed it on his workstation, tested it, fixed a couple of bugs in our code and then check the project back in. The problem is that we did not accept the library for production and he had unreference the third party library and rereferenced the new library before the check in, our build system still had the older library so it was producing broken builds.

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups