Using language DLLs for strings ONLY

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



(Cross-posted to ms.public.windowsce.embedded, sorry to people who read
both groups)

I've created a per-language DLL with some string resources and when my
app loads I'm trying to load the module and get the string resources
from there instead.

The test code that does it is simply:
HINSTANCE hRes = NULL;
hRes= LoadLibrary(_T("res0C0A.dll"));
if (hRes)
AfxSetResourceHandle(hRes);

My problem is that after setting the resource handle to the other DLL,
the app tries to load ALL resources from that DLL (which of course
fails).

It seems my options are either to create virtually identical DLL's
(with the exception of the translated strings) or to subclass CString
and read strings from the int'l DLL but other resource from the app's
resources.

Are these my only two options? Or am I overlooking something else?

Thanks,
Dan.

.



Relevant Pages

  • Re: Using language DLLs for strings ONLY
    ... CString::LoadString(UINT id, HINSTANCE dll), but that would be too much like blindingly ... Do not consider subclassing CString. ... >I've created a per-language DLL with some string resources and when my ...
    (microsoft.public.vc.mfc)
  • Re: internationalisation
    ... Load the desired DLL and keep a local resource handle ... When we implemented language support in RIP Vinyl, we decided to go with a ... system of including all of the resources in the main exe, ...
    (microsoft.public.vc.mfc)
  • Using language DLLs for strings ONLY
    ... I've created a per-language DLL with some string resources and when my ... app loads I'm trying to load the module and get the string resources ... My problem is that after setting the resource handle to the other DLL, ...
    (microsoft.public.windowsce.embedded.vc)
  • Re: multiple dll or one String Table?
    ... I typically do mutiple DLLs since I have a lot of GUI resources and I don't ... It's easy enough to load the DLL ... at least one language is built in. ...
    (microsoft.public.vc.language)
  • Re: resource-only dll
    ... so it *must* have an entry point, in order to get an HMODULE? ... >> basically, there is a load of resources, in a dll. ...
    (microsoft.public.vc.language)