Multi Commander Support Forum

Multi Commander => Feature Requests and Suggestions => Topic started by: total_annihilation00 on April 27, 2024, 11:35:46

Title: "Open file location" for Links Needed for MultiCommander
Post by: total_annihilation00 on April 27, 2024, 11:35:46
What does "Show HotPath" (Ctrl+,) do ? I want a feature to Goto the the actual file path of an link (.lnk). Windows Explorer has a function for this ("Open file location") in Right-click menu, but it opens it in Explorer, wish MC had a similar function !! Is there a workaround to add this functionality ? Otherwise thrilled /w the new features & options !  :D
P.S: I would like to add the "Open file location" command to MC's "Custom Context Menu".
Title: Re: "Open file location" for Links Needed for MultiCommander
Post by: Jungle on April 27, 2024, 14:15:38
MC has a MultiScript function GetWinShortcutTarget(). So the simplest multiscript UDC could look like:
Code: [Select]
@var $lnk = GetSourceFocusPath();

@var $path = GetWinShortcutTarget( $lnk );
MC.Explorer.Goto SOURCE="{$path}";
Title: Re: "Open file location" for Links Needed for MultiCommander
Post by: total_annihilation00 on April 27, 2024, 18:36:00
MC has a MultiScript function GetWinShortcutTarget(). So the simplest multiscript UDC could look like:
Code: [Select]
@var $lnk = GetSourceFocusPath();

@var $path = GetWinShortcutTarget( $lnk );
MC.Explorer.Goto SOURCE="{$path}";

Thanks a lot, appreciate it !! That works brilliantly ! 8) Using it in "Custom Context Menu" after creating an UDC. I named it "Goto Actual FilePath Link" and used the filter *.lnk to work only on link files.
P.S: It also works on .qalnk files (QuickAdmin UAC-Bypass shortcut files) —that's an added bonus !!
P.P.S: Currently it doesn't work on Microsoft Store Apps shortcuts or DOSBox Games Launcher .lnk shortcuts (takes you to the DOSBox Games Launcher folder —maybe this is not a bug as it permeates through 3 different files when accessed.) Not that this is important, but thought I should let you know.