title: MFC LoadString fails when attempting to load a string from afxres.rc
body: <p>When my program attempts to generate an AFX_IDP_PARSE_REAL error for the user, it fails to load the string that is stored in the afxres.rc file.  I found <a href="https://stackoverflow.com/questions/11862139/loadstringafx-idp-parse-int-fails-in-an-mfc-exe-not-in-a-dll">this question</a> already, however it was solved because the reference to afxres.rc was accidentally deleted from the program.rc file.  That is not the case for me.  My program.rc file includes the exact code listed in the answer to include the afxres.rc file.</p>
  
  <p>In debug mode, it breaks on the ASSERT below.</p>
  
  <pre><code>int AFXAPI AfxMessageBox(UINT nIDPrompt, UINT nType, UINT nIDHelp)
  {
   CString string;
   if (!string.LoadString(nIDPrompt))
   {
    TRACE(traceAppMsg, 0, "Error: failed to load message box prompt string 0x%04x.\n", nIDPrompt);
    ASSERT(FALSE);
   }
   if (nIDHelp == (UINT)-1)
   nIDHelp = nIDPrompt;
   return AfxMessageBox(string, nType, nIDHelp);
  }
  </code></pre>
  
  <p>When I am actually running the application via the .exe, it simply generates an empty warning box since the AFX_IDP_PARSE_REAL string is not loaded; this goes for any string in the afxres.rc.</p>
  
  <p>What could cause the application to not load the string from the afxres.rc?</p>