locked
The resource class for this page was not found. RRS feed

  • Question

  • User681036950 posted
     I have created a resource file using the Tools>Generate Local Resource.  For some reason when I 
    run my website locally I am not able to see any of the resource strings.  I have the correct
    syntax in the html - 
    <asp:label id="lblPhoneNumber" runat="server" meta:resourcekey="PhoneNumber"/>
     
    My page is being loaded into a javascript tab control and I believe this is the reason it can't find 
    the App_LocalResources resx file. I have tried adding the App_LocalResources folder and it's
    contents to several logical places that it might be looking, but I've had no luck..
    Does anyone know how I can locate where VS 2008 is looking for the resource file? 
     
    Friday, March 6, 2009 6:11 PM

Answers

  • User756774649 posted
    One issue: when you're using the automatic generation tool ... it should create App_LocalResources and also create a .resx file for your page. If that didn't happen then you definitely got a problem there. So are they created or not?
    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, March 6, 2009 8:46 PM

All replies

  • User756774649 posted
    One issue: when you're using the automatic generation tool ... it should create App_LocalResources and also create a .resx file for your page. If that didn't happen then you definitely got a problem there. So are they created or not?
    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, March 6, 2009 8:46 PM
  • User681036950 posted

     Yeah, both the App_LocalResource folder and the resx file(Build set to content) were created.  Also, I created a test website and created a test resource file for that and it worked fine so I can get it to work on a basic site, just not for the main site with the page hosted in tabs.

     

    Thanks for any help...

    Friday, March 6, 2009 10:13 PM
  • User681036950 posted

     I figured out how to solve this issue.  First I had to make the project I added to the ASP.Net solution a virtual directory.  Then I had to put the necessary   <location path="." inheritInChildApplications="false"> tags in the root web.config file. After that the issue was that my aspx page was in a subdirectory.  So the structure looked like Website/Test/Test.  Once I moved all of the contents of the project up one directory it worked.

    Thursday, March 12, 2009 3:19 PM