localization with string table

This is a discussion on localization with string table within the Windows Programming forums, part of the Platform Specific Boards category; Hi, I am beginner to windows programming. I am trying with a sample program that displays a localized string. I ...

  1. #1
    Registered User
    Join Date
    Jul 2005
    Posts
    8

    localization with string table

    Hi, I am beginner to windows programming. I am trying with a sample program that displays a localized string. I folllowed the steps below:
    1. Created a win32 application in VC6. Set _UNICODE and UNICODE as the preprocessor definitions.
    2. Added a resource file to the project. Added two string tables in the resource file, one for japanese locale and other for english(US) locale. Both the string tables contain only one entry with the same ID, but differrent caption.
    3. WinMain contains only two statements: one for LoadSring() and other for MessageBox().

    My intention is to display localized message. When I run the program on both english and jpanese locales, I get the same string( which is from the english string table ).

    What is the problem? Did i miss anything?


    TIA,
    Vivek

  2. #2
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    8,048
    Isn't that what's supposed to happen?
    dwk

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell


    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ: cpwiki.sf.net

    My website: http://dwks.theprogrammingsite.com/
    Projects: codeform, xuni, atlantis, nort, etc.

  3. #3
    Even death may die... Dante Shamest's Avatar
    Join Date
    Apr 2003
    Location
    Malaysia
    Posts
    970
    I was under the impression that for programs running on different locales, you distributed them with different strings. Or at least give them different IDs, and allow the user to specify which language to use.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Program using classes - keeps crashing
    By webren in forum C++ Programming
    Replies: 4
    Last Post: 09-16-2005, 04:58 PM
  2. Linked List Help
    By CJ7Mudrover in forum C Programming
    Replies: 9
    Last Post: 03-10-2004, 10:33 PM
  3. Classes inheretance problem...
    By NANO in forum C++ Programming
    Replies: 12
    Last Post: 12-09-2002, 03:23 PM
  4. creating class, and linking files
    By JCK in forum C++ Programming
    Replies: 12
    Last Post: 12-08-2002, 02:45 PM
  5. Warnings, warnings, warnings?
    By spentdome in forum C Programming
    Replies: 25
    Last Post: 05-27-2002, 07:49 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21