1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How to get localized "Flight Simulator X files" folder ?

Discussion in 'Tools programming' started by JAB, 23/2/07.

  1. JAB

    JAB

    Joined:
    13/10/06
    Messages:
    16
    Country:
    switzerland
    Hello,

    As you probably noticed, the name of the folder where FSX places saved flights is localized. It is always in "My Documents" (or localized equivalent)
    but the name changes.

    In english it is "Flight Simulator X Files"
    In french it is "Fichier Flight Simulator X"

    Does anybody know where to find this information ?
    It is not in registry, it is not if cfg files ... it should be somewhere ...

    Thanks in advance for your help

    A+
    Jacky
  2. theisomizer

    theisomizer

    Joined:
    15/1/07
    Messages:
    157
    Country:
    us-texas
    It uses the same localization scheme (language codes) as windows. For example, 1033 is the code for English.

    This value is stored as a dword in: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\microsoft games\flight simulator\10.0 as LangID.

    For example my LangID is 00000409. This is the DWORD value for 1033.

    So now that you know the language the product is in, you can deduce what the name of the folder is.

    I'll bet if you google it you can find a list of all of the language codes without too much trouble.

    Hope this helps,
    Sean
  3. JAB

    JAB

    Joined:
    13/10/06
    Messages:
    16
    Country:
    switzerland
    HiSean,

    Thanks for your reply.
    But it doesn't help to find the name of the folder ! :confused:

    Example : In the registry, I find that the language is 405 (dec 1029) = Czech.
    How can I deduce the folder's name ??? :eek:

    A+
    Jacky
  4. scruffyduck

    scruffyduck Administrator Staff Member FSDevConf team Resource contributor

    Joined:
    17/9/05
    Messages:
    23,273
    Country:
    wales
    I think you are asking about how the names of folders are rendered in different cultures?

    I have no idea how it is managed. I have not checked but I assume that the Registry contains a number of keys for different elements of the set-up. One of them is certainly the FS Application folder. Is there another one for the Flights Folder?
  5. Pete Dowson

    Pete Dowson

    Joined:
    25/9/06
    Messages:
    315
    Country:
    unitedkingdom
    It's a resource in the LANGUAGE.DLL in the FSX folder. Try something like this:

    HINSTANCE hInstLang = LoadLibrary("<fsx folder>\language.dll");
    if (hInstLang)
    { LoadString(hInstLang, 36864, szFSXfilesfolder, 128))
    FreeLibrary(hInstLang);
    }
    else ...

    where obviously you need code to insert the FSX folder path.

    Regards

    Pete
  6. moustache

    moustache

    Joined:
    27/11/06
    Messages:
    2
    Country:
    france
    Ouaip!

    with InstallCreator


    HKEY_LOCAL_MACHINE

    Software\Microsoft\Microsoft Games\Flight Simulator\10.0

    setupPath

    :wave:
  7. Pete Dowson

    Pete Dowson

    Joined:
    25/9/06
    Messages:
    315
    Country:
    unitedkingdom
    Pardon? I'm not familiar with that one!

    That certainly gives you the FSX path (not the My Documents FSX Files path). Is that waht you were intending to say?

    Regards

    Pete
  8. JAB

    JAB

    Joined:
    13/10/06
    Messages:
    16
    Country:
    switzerland
    Hello,

    Thanks everybody for your answers !

    Pete gave the solution I was looking for ! :)
    Thanks Pete !

    A+
    Jacky

Share This Page