Multi Commander > Support and Feedback
Aliases Launched Exe's Get Current Tab As Startup Folder Not Origin Root Folder
total_annihilation00:
Issue Description:
When launching applications via Aliases, the active tab's path (representing the current working directory) is being assigned as the configuration or log file storage location instead of the application's actual startup directory. Specifically, the application’s startup folder, as defined in the executable’s properties (the "Startup Folder" in the Exe Properties), is not being used as the working directory upon launch.
Details:
* For example, launching Yahoo-8Ball-Pool-Clone.exe via an alias ("8ball") like:
--- Code: ---!"D:\Download\cpp-projekt\FuzenOp_SiloTest\Release\Yahoo-8Ball-Pool-Clone.exe"
--- End code ---
results in the current tab being D:\Download\AutoHotkey\Compiler\, and the application writes its config/log files into this directory instead of its intended startup directory (in my case the "Pool-Settings.txt" config file was placed in here erroneously).
* The root cause appears to be that the application’s working directory is incorrectly set to the active tab (the current working directory in the shell or environment), rather than the "Startup Folder" as specified in the executable properties.
* This causes files that are supposed to be stored in the application's startup directory to instead be stored in the current tab's directory, leading to misplaced configuration files and logs.
Summary:
The launch mechanism via Aliases incorrectly assigns the current working directory (the open tab) as the application's working directory, instead of using the executable's designated startup folder. This behavior constitutes a bug in how the environment initializes the app's working context upon launch.
Mathias (Author):
Not a bug, but a feature. :)
Example. I assign alias "n" to "Notepad2.exe" then I can do "n newfile.txt" and I get the new file in the current folder.
Not sure if both situation can work.. Maybe create a shortcut for the .exe that needs its working dir and execute that via alias
total_annihilation00:
Oh I see, well I feared it would come to that —I'll link to a shortcut then. ;D
P.S: Wait, will making a User Defined Command to hotlink the file work ? Nvm, I'll stick to using a shortlink .LNK. User Defined Commands > Custom Commands > Run; seems to do the trick !
Mathias (Author):
--- Quote from: total_annihilation00 on Yesterday at 08:45:29 ---Oh I see, well I feared it would come to that —I'll link to a shortcut then. ;D
P.S: Wait, will making a User Defined Command to hotlink the file work ? Nvm, I'll stick to using a shortlink .LNK.
--- End quote ---
You can also create a UserDefinedCommand that start it, and then call the UDC from alias using ID of the script. .Just out a @ in front of the id
Like @6d35f84f73a74dfbb16ca370ccb625f7
Maybe can add so a special character first of the command tells it to use the command paths as working folder.. like maybe "$" instead of "!", I check if that possible
total_annihilation00:
--- Quote from: Mathias (Author) on Yesterday at 09:01:48 ---You can also create a UserDefinedCommand that start it, and then call the UDC from alias using ID of the script. .Just out a @ in front of the id
Like @6d35f84f73a74dfbb16ca370ccb625f7
--- End quote ---
Yeah, I'am way ahead of ya… 😂
Navigation
[0] Message Index
[#] Next page
Go to full version