Search code examples
windowsansiregional-settings

WIll the system directories in different languages have the same path as the default system ones?


I'm trying to reach a japanese path. Something like "C:\日本語\asd.dll", but I have some problems. If I force my installer to put the dll file to C:\Windows\System32, will that path be the same in all language versions of Windows or it will be in the regional language?


Solution

  • No, you cannot in general rely on paths being the same. Always use the environment variables - you can guarantee that the environment variable names will not be localized (i.e. "%SystemRoot%" works everywhere). In your example, you would want to put the file in %SystemRoot%\System32.

    Though, I would advise to not be putting DLLs in this directory, as it belongs to the OS.