Why Does TerminalInfoString(TERMINAL_DATA_PATH) Show the Broker Name?

 
Hi,

I noticed that TerminalInfoString(TERMINAL_DATA_PATH) returns a path including the broker's name, like:

C:\Users\[username]\AppData\Roaming\[BrokerName]

instead of the usual:

C:\Users\[username]\AppData\Roaming\MetaQuotes\[number]

Does anyone know why this happens and how to reset it to the default?

Thanks!
 
Is the directory name correct or wrong? If its correct, why bother. 
Usually the subdirectory names are nothing else but the crypted name of the installation folder within C:/Programs. Its a one way hash-encryption, but does not have to be by standard. 
 

Thank you for your response. I appreciate the clarification and the details provided.

After receiving more information from a customer, I discovered that their AppData/Roaming/[BrokerName] folder contains not only data files but also the terminal.exe and other executable files. It appears that MT4 is running in /portable mode, which likely explains why TerminalInfoString(TERMINAL_DATA_PATH) points to this location.


Typically, I understand that portable mode is used to place the installation in a more flexible or easily movable location, such as an external drive or a specific directory chosen by the user. However, in this case, the portable setup is located under the AppData folder.


This makes me wonder: why would someone set up portable mode in a location like AppData, and does this approach provide any meaningful advantages? I’d appreciate any thoughts or insights on this. It seems like a folder structure that could cause misunderstanding...

Thanks