System.IO.FileNotFoundException: Could not load file or assembly 'App_GlobalResources' or one of its dependencies. RRS feed

  • Question

  •  Hello,

    I have a project that have resources in App_GlobalResources folder in which .resx files' custom tool are set to GlobalResourceProxyGenerator.

    So that I can use my resouce files like 


    This works without any problems.

    However when I add UnitTests to my project and run those tests, whenever main application uses the resources it throws following exception:
     System.IO.FileNotFoundException: Could not load file or assembly 'App_GlobalResources' or one of its dependencies.

    I have been searching for a possible solution for a week but no chances. I have a co-worker here in the same company who has the same problem in different project.

    Is this a known bug or do we do something wrong?

    Thanks in advance.

    Yusuf Demirag

    • Moved by Zhi-Xin Ye Friday, September 12, 2008 10:34 AM asp.net (Moved from .NET Base Class Library to Off-Topic Posts (Do Not Post Here))
    Monday, September 8, 2008 9:28 AM


All replies

  • The probing path for your unit test .exe is probably wrong.  Did you try running it from the same path as your regular .exe?
    Hans Passant.
    Monday, September 8, 2008 1:07 PM
  • Hello Hans,

    The main application is webservices. And the UnitTests are calling the functions from this service. When a webservice function doesnt use resources, test runs without any problems. But when a webservice function consumes resources, test function throws  System.IO.FileNotFoundException. I tried to copy App_GlobalResources folder to test project but didnt work. Still no clue why this is happening. Any more ideas?

    Monday, September 8, 2008 1:28 PM
  • I have no idea what an "App_GlobalResources" folder is.  Sounds like an ASP.NET thingy.  ASP.NET questions are handled at forums.asp.net
    Hans Passant.
    Monday, September 8, 2008 11:00 PM

    Hello Yusuf,


    Thank you for your post!  I would suggest posting your question in one of the MS Forums, 

    Have a great day!

    Friday, October 31, 2008 3:16 PM
  • Shame on you for marking your post as an answer.  Not only is it not an answer, it wasn't an original answer either.  Next time, change the thread type to Discussion.
    Hans Passant.
    Monday, March 23, 2009 1:25 PM
  • I ended up with this App_GlobalResources error for any ASP.NET site all of a sudden.  Fastest way to solve it (and easiest) is to uninstall IIS Express and reinstall.  Worked right away, honestly.
    Thursday, September 11, 2014 6:41 PM