specify separate paths per pane in .lnk

Please check the FAQ (https://www.xyplorer.com/faq.php) before posting a question...
rhino
Posts: 8
Joined: 30 Mar 2018 00:39

specify separate paths per pane in .lnk

Post by rhino »

Hi all,
sorry for the newbie question :
- basic windows shortcut to open XYplorer
- how can I specify separate startup directories for both panes, please ?
- like

Code: Select all

 "C:\Program Files (x86)\XYplorer\XYplorer.exe" C:
except I want to specify a path for the 2nd tab, too
- same idea as the dual permanent startup paths, but set in the .lnk, not permanent

thanks for any help,
Rhino

jupe
Posts: 3565
Joined: 20 Oct 2017 21:14
Location: Win10 22H2 120dpi

Re: specify separate paths per pane in .lnk

Post by jupe »

There are a few ways of doing this, here is one:

"%PROGRAMFILES(x86)%\XYplorer\XYplorer.exe" /feed="::focus 'P1'; goto 'c:\Windows'; if !(get('#800')){#800;} focus 'P2'; goto 'c:\';"

I used C:\ and C:\Windows in this example, so adjust to the paths you want

rhino
Posts: 8
Joined: 30 Mar 2018 00:39

Re: specify separate paths per pane in .lnk

Post by rhino »

hello jupe,
thanks for your suggestion !

unfortunately all it does is open XYplorer the generic way, exactly like
"%PROGRAMFILES(x86)%\XYplorer\XYplorer.exe"
my own command
"C:\Program Files (x86)\XYplorer\XYplorer.exe" C:
at least sets the target for one pane ...

any other ideas ?
thanks,
Rhino

btw, it's W7/64 Pro SP1, but I guess the syntax is universal
XYplorer 18.90.0100

jupe
Posts: 3565
Joined: 20 Oct 2017 21:14
Location: Win10 22H2 120dpi

Re: specify separate paths per pane in .lnk

Post by jupe »

It works fine for me, please show the exact string including your desired paths you have in the lnk target box, the quoting needs to remain exactly as I have it.

edit: sorry it looks like I added extra outside quotes by accident initially

highend
Posts: 15016
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: specify separate paths per pane in .lnk

Post by highend »

Try it this way (outer double quotes removed)

Ofc what's inside the code block is a single line (and you have to adapt both paths)...

Code: Select all

"%PROGRAMFILES(x86)%\XYplorer\XYplorer.exe" /feed="::if !(get('#800')){#800;} focus 'P2'; goto 'c:\';focus 'P1'; goto 'c:\Windows';"
One of my scripts helped you out? Please donate via Paypal

rhino
Posts: 8
Joined: 30 Mar 2018 00:39

Re: specify separate paths per pane in .lnk

Post by rhino »

Hi folks,
thanks, but still no luck.
here's what my shortcut looks like, with your example pasted in :
(it's the complete command, obviously, the display only shows the 2nd half)
Image
I would expect to see :
- tree on the left
- pane A : c:\
- pane B : c:\Windows
(or vice versa)
after running your shortcut, correct ?

I also tried running the .lnk as admin, and on a completely unprotected offline workstation, so it can't be an AV problem either.
what am I doing wrong ?

thanks,
Rhino
Last edited by rhino on 30 Mar 2018 13:26, edited 1 time in total.

highend
Posts: 15016
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: specify separate paths per pane in .lnk

Post by highend »

vice versa

Let's do it differently. What happens if you open a (non admin) command prompt and paste the whole stuff (the code block from my last posting) in there and execute it? Any error message? If not, do it again but this time use this:

Code: Select all

"%PROGRAMFILES(x86)%\XYplorer\XYplorer.exe" /feed="::step; if !(get('#800')){#800;} focus 'P2'; goto 'c:\';focus 'P1'; goto 'c:\Windows';"
Do you get the "Stepping through a Script" window then?
One of my scripts helped you out? Please donate via Paypal

jupe
Posts: 3565
Joined: 20 Oct 2017 21:14
Location: Win10 22H2 120dpi

Re: specify separate paths per pane in .lnk

Post by jupe »

I know you say you are running 18.90, but if by chance you don't get a stepping window after following the above suggestion you may actually be running an earlier version from that location in which case you may need to change /feed into /script instead

rhino
Posts: 8
Joined: 30 Mar 2018 00:39

Re: specify separate paths per pane in .lnk

Post by rhino »

thanks, tried both versions via command prompt.
also tried "run" from start menu.
same result, XYplorer opens "my computer", twice.
no stepping windows or stuff ...

as my own simple shortcut

Code: Select all

"C:\Program Files (x86)\XYplorer\XYplorer.exe" D:
works for the active pane at least (or the upper pane if XYplorer was not open), wouldn't it be possible to append a path for the other pane ?

sorry to be a pain,
Rhino

updated yesterday, title bar and about confirm latest version
Last edited by rhino on 30 Mar 2018 13:47, edited 1 time in total.

highend
Posts: 15016
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: specify separate paths per pane in .lnk

Post by highend »

So you didn't get the stepping through a script window? Then you must be calling a different instance of XY (an older one)...

And show a screenshot from the Help - About XYplorer window
One of my scripts helped you out? Please donate via Paypal

rhino
Posts: 8
Joined: 30 Mar 2018 00:39

Re: specify separate paths per pane in .lnk

Post by rhino »

edited my previous post while you were writing.
Image

thanks,
Rhino

highend
Posts: 15016
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: specify separate paths per pane in .lnk

Post by highend »

Code: Select all

"C:\Program Files (x86)\XYplorer\XYplorer.exe" /script="::echo 'hello';"
What happens if you do this, do you get a window from XY, containing the text "hello"?
'
One of my scripts helped you out? Please donate via Paypal

rhino
Posts: 8
Joined: 30 Mar 2018 00:39

Re: specify separate paths per pane in .lnk

Post by rhino »

sorry for the delay, client phone call. :roll:
highend wrote:

Code: Select all

"C:\Program Files (x86)\XYplorer\XYplorer.exe" /script="::echo 'hello';"
What happens if you do this, do you get a window from XY, containing the text "hello"?
'
nope, XY opens in default view, that's all.

it's the portable version, does that make a difference ?
or do I have to enable scripting manually somewhere ?
thanks,
Rhino

highend
Posts: 15016
Joined: 06 Feb 2011 00:33
Location: Win Server 2022 @100%

Re: specify separate paths per pane in .lnk

Post by highend »

Why did you disable scripting? oO

Configuration | Other | Features | Scripting
One of my scripts helped you out? Please donate via Paypal

rhino
Posts: 8
Joined: 30 Mar 2018 00:39

Re: specify separate paths per pane in .lnk

Post by rhino »

highend wrote:Why did you disable scripting? oO

Configuration | Other | Features | Scripting
bingo, we have a winner ! :appl:
everything works now, tried different paths already.
brilliant - problem solved !
child's play to adapt from here.

no, I did not disable scripting (at least not knowingly).
I started out with Free long ago, had a one year license, let it expire for a while, recently bought lifetime (convinced by the changelogs), so it probably got lost somewhere along the way.
up until now, the multitude of "regular" features always served me fine, I didn't really consider scripting for my needs (and never checked its status).

sorry for not seeing the forest for all the trees ...
I really appreciate your patience !
many many thanks, both of you, happy holidays !
Rhino

Post Reply