Sunday, April 3, 2011

What is the difference between a resource file and a satellite DLL?

I am not getting the difference between resource files and satellite dll.

From stackoverflow
  • They are very similar, Satelite Dlls are for Translated resources.

    Tim Jarvis : Actually, I just looked and there are a lot of similar questions on this, you might like to delete this one.
  • Ressource files usually get compiled into the application. A satellite dll is a dll, that includes all the ressources of an application and in addition, through its special nomenclature can be loaded based on the country schema, that is regional settings.

    409 : LocaleID for English (United States)
    40C : LocaleID for French (Standard)
    

    When I name my dll testSAT40C.dll, it will be loaded when I'm working when selecting regional settings for France.

    You can then get ressoirces using

         If (LoadLocalizedResources) Then
    
            ' Pull a string resource out of a local resource
            ' object for demonstration purposes.
            Command1.Caption = GetString(101)
         End If
    

    For a complete example (including the code for the functions GetString and LoadLocalizedResources) look here. (I know the sample is in VB6, but easy enough to port to other languages.)

0 comments:

Post a Comment