Best practice to handle "Resource Only Dlls"

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

From the MFC-days we have an app, and depending on the users choice of
international standard and language we load the appropriate resource only dll
and pull the strings and other resources from there. This it not dependent on
neither culture nor O/S.

Is there a good approach to to this in .net? The resources must be in
separate file from the app. In MFC you just set up the dll to be Resource
Only and that was about done.

/Matt
 
Hello,

zatopek said:
From the MFC-days we have an app, and depending on the users choice of
international standard and language we load the appropriate resource only
dll
and pull the strings and other resources from there. This it not dependent
on
neither culture nor O/S.

Is there a good approach to to this in .net? The resources must be in
separate file from the app. In MFC you just set up the dll to be Resource
Only and that was about done.

That's the default behavior in .NET. The main language is kept in the
program assembly, and each language gets its own folder under the program
directory, named by the language code.

Best regards,
Henning Krause
 
Can I load this dll from somewhere else?
It was easy to just change the culture.

But is it possible to have this dll anywhere with any name and just tell the
app to use it?
 
Is there a good approach to to this in .net? The resources must be in
separate file from the app. In MFC you just set up the dll to be Resource
Only and that was about done.

You can start from here:
http://msdn2.microsoft.com/en-us/library/z68135h5(VS.71).aspx

Long story short: change the forms property to localizable, and change the
language of the form to the language you want to add.
You should do this for each form, there is no global setting :-(
When you build the resource only dll is created in the proper place and with
the proper name for the resource manager to find it.
In order to use it you will just set the CurrentUICulture to the language you
want.
 
Back
Top