Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. changing windows language in the code

changing windows language in the code

Scheduled Pinned Locked Moved C / C++ / MFC
question
12 Posts 5 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • _ _AnsHUMAN_

    iayd wrote:

    I wrote this code but I don't know if it should cahnge the language:

    Then why did you write it, if you didn't know what this would do...

    iayd wrote:

    How can I do that if that is possible?

    You didn't try to bother about gathering the information on how to achieve this.

    iayd wrote:

    ConvertDefaultLocale(LANGUAGE);

    The ConvertDefaultLocale function converts a default locale value to an actual locale identifier.

    Somethings seem HARD to do, until we know how to do them. ;-)_AnShUmAn_

    I Offline
    I Offline
    iayd
    wrote on last edited by
    #3

    Do you have any helpful answer?

    _ 1 Reply Last reply
    0
    • I iayd

      Do you have any helpful answer?

      _ Offline
      _ Offline
      _AnsHUMAN_
      wrote on last edited by
      #4

      iayd wrote:

      Do you have any helpful answer?

      You can go to my profile and see the usefulness of the posts. not many, but you will find places where my answers helped. I could have helped you only if I understood your problem correctly. Don't you think that with the information you provide it would be difficult to get the answer? The usefulness of the answer comes into picture, it is directly proportional to the complexity and explanation of the problem in your query.

      Somethings seem HARD to do, until we know how to do them. ;-)_AnShUmAn_

      modified on Thursday, August 14, 2008 8:13 AM

      1 Reply Last reply
      0
      • I iayd

        Hi, I want to change windows language in the code.How can I do that if that is possible? I wrote this code but I don't know if it should cahnge the language:

        WORD lang = MAKELANGID(LANG\_ENGLISH,SUBLANG\_NEUTRAL);
        DWORD LANGUAGE = MAKELCID(lang,SORT\_DEFAULT);
        ConvertDefaultLocale(LANGUAGE);
        

        Thanks, ibrahim

        S Offline
        S Offline
        SandipG
        wrote on last edited by
        #5

        If i am not mistaken i am reading your question for 4th or 5th time you have some problem with showing something in Arabic language rite. if some one here had an answer you would have got it in 1st post or 2nd surely. I am not sure if it will help you but, There are some good localization articles here on CP, I dont know whether you have seen them. Here are few of them. http://www.codeproject.com/KB/locale/MultiLangSupportMFCExtDLL.aspx[^] http://www.codeproject.com/KB/locale/multilingual.aspx[^] I hope it helps. and while posting please frame your query properly also with the background about what have you done so far it will help you in getting proper answer. All the best :)

        Regards, Sandip.

        I 1 Reply Last reply
        0
        • S SandipG

          If i am not mistaken i am reading your question for 4th or 5th time you have some problem with showing something in Arabic language rite. if some one here had an answer you would have got it in 1st post or 2nd surely. I am not sure if it will help you but, There are some good localization articles here on CP, I dont know whether you have seen them. Here are few of them. http://www.codeproject.com/KB/locale/MultiLangSupportMFCExtDLL.aspx[^] http://www.codeproject.com/KB/locale/multilingual.aspx[^] I hope it helps. and while posting please frame your query properly also with the background about what have you done so far it will help you in getting proper answer. All the best :)

          Regards, Sandip.

          I Offline
          I Offline
          iayd
          wrote on last edited by
          #6

          Yes I wrote similar questions but I coudn't get an answer.I am suprising to this because I asked several hard questions according to me to this forum and I got good answers until now.so I thought that the experts on visual c++ didn't see my question.But maybe I should try some other ways. Thanks

          D 1 Reply Last reply
          0
          • I iayd

            Hi, I want to change windows language in the code.How can I do that if that is possible? I wrote this code but I don't know if it should cahnge the language:

            WORD lang = MAKELANGID(LANG\_ENGLISH,SUBLANG\_NEUTRAL);
            DWORD LANGUAGE = MAKELCID(lang,SORT\_DEFAULT);
            ConvertDefaultLocale(LANGUAGE);
            

            Thanks, ibrahim

            N Offline
            N Offline
            Nemanja Trifunovic
            wrote on last edited by
            #7

            iayd wrote:

            I want to change windows language in the code

            Not sure what you mean by "change windows language". Do you want to change the system locale, user locale, input locale, thread locale or UI language? Basically, you can programatically change only the thread locale, and for that you need to call SetThreadLocale function. The thread locale determines things like formatting of dates and currency for the thread.

            Programming Blog utf8-cpp

            1 Reply Last reply
            0
            • I iayd

              Yes I wrote similar questions but I coudn't get an answer.I am suprising to this because I asked several hard questions according to me to this forum and I got good answers until now.so I thought that the experts on visual c++ didn't see my question.But maybe I should try some other ways. Thanks

              D Offline
              D Offline
              David Crow
              wrote on last edited by
              #8

              iayd wrote:

              ...I asked several hard questions according to me to this forum and I got good answers until now.so I thought that the experts on visual c++ didn't see my question.But maybe I should try some other ways.

              Did you ever stop to think for a moment that those "hard" questions were: 1) not hard at all, or 2) posted at just the right time as to be seen by the majority? Posts go unanswered for many reasons.

              "Love people and use things, not love things and use people." - Unknown

              "The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch

              1 Reply Last reply
              0
              • I iayd

                Hi, I want to change windows language in the code.How can I do that if that is possible? I wrote this code but I don't know if it should cahnge the language:

                WORD lang = MAKELANGID(LANG\_ENGLISH,SUBLANG\_NEUTRAL);
                DWORD LANGUAGE = MAKELCID(lang,SORT\_DEFAULT);
                ConvertDefaultLocale(LANGUAGE);
                

                Thanks, ibrahim

                D Offline
                D Offline
                David Crow
                wrote on last edited by
                #9

                Have you tried SetThreadLocale()?

                "Love people and use things, not love things and use people." - Unknown

                "The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch

                I 1 Reply Last reply
                0
                • D David Crow

                  Have you tried SetThreadLocale()?

                  "Love people and use things, not love things and use people." - Unknown

                  "The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch

                  I Offline
                  I Offline
                  iayd
                  wrote on last edited by
                  #10

                  I tried that.But it doesn't change the language.I want that when I achieve to change the language, I would be able to write in arabic to an editbox after I changed the language from english to arabic.I can do that manually by changing the language of windows by tabbing to alt + shift. Thanks

                  N 1 Reply Last reply
                  0
                  • I iayd

                    I tried that.But it doesn't change the language.I want that when I achieve to change the language, I would be able to write in arabic to an editbox after I changed the language from english to arabic.I can do that manually by changing the language of windows by tabbing to alt + shift. Thanks

                    N Offline
                    N Offline
                    Nemanja Trifunovic
                    wrote on last edited by
                    #11

                    iayd wrote:

                    I would be able to write in arabic to an editbox after I changed the language from english to arabic.I can do that manually by changing the language of windows by tabbing to alt + shift.

                    How about ActivateKeyboardLayout()[^] function?

                    Programming Blog utf8-cpp

                    I 1 Reply Last reply
                    0
                    • N Nemanja Trifunovic

                      iayd wrote:

                      I would be able to write in arabic to an editbox after I changed the language from english to arabic.I can do that manually by changing the language of windows by tabbing to alt + shift.

                      How about ActivateKeyboardLayout()[^] function?

                      Programming Blog utf8-cpp

                      I Offline
                      I Offline
                      iayd
                      wrote on last edited by
                      #12

                      Thanks Nemanja. That solved my problem.

                      1 Reply Last reply
                      0
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      • Login

                      • Don't have an account? Register

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • World
                      • Users
                      • Groups