Home » Development » Solved: “The resource object with key ‘X’ was not found”

Solved: “The resource object with key ‘X’ was not found”

You may run into the error below when you use a WebResource file in your ASP.NET project.
Server Error in ‘/UMregistration’ Application.
Parser Error
Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.
Parser Error Message: The resource object with key ‘FooterInfoMsg’ was not found.



In order to fix it:
  1. Right click on your resource (resx) file
  2. Go to Properties
  3. Change “Build Action” to “Content”

Capture2Not working?

If the solution above doesn’t work, try “Embedded Resource” option for “Build Action” parameter.

If you are still getting the same error, try changing “Copy to Output Directory” value to “Copy Always”. A folder named “App_GlobalResources” will be created when you publish the code. Make sure this folder is in the same location as the page that is giving resource file connection error.

Ned Sahin

Blogger for 20 years. Former Microsoft Engineer. Author of six books. I love creating helpful content and sharing with the world. Reach me out for any questions or feedback.

Leave a Comment