Bug when launching from command line

Things you’d like to miss in the future...
Post Reply
sinilill
Posts: 111
Joined: 02 Dec 2013 18:37

Bug when launching from command line

Post by sinilill »

I'm launching XYplorer via command line with a file path and get different result when XY is running and when not. It is only happening with locations like Desktop and Userprofile.

When XY is running and I try to launch myfile.txt which is on my desktop, then XY tries to go to XYinstallDIR\Desktopmyfile.txt\
When XY is not running and I launch the same command, then XY is starting, opens a new tab and selects the myfile.txt file

Same happens with the Userprofile folder, XY want's to go to XYinstallDIR\USERmyfile.txt\
When not running XY opens the USER folder and selects myfile.txt

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

Re: Bug when launching from command line

Post by highend »

And you don't want to show us the exact command, that you're executing? :eh:
One of my scripts helped you out? Please donate via Paypal

sinilill
Posts: 111
Joined: 02 Dec 2013 18:37

Re: Bug when launching from command line

Post by sinilill »

I'm launching it from AkelPad's toolbar: XYplorer.exe %f, %f is the filepath.

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

Re: Bug when launching from command line

Post by highend »

Works fine for me when I execute XY from it with a file on my desktop.

You did surround the %f param with double quotes in AkelPads general tab setting?
One of my scripts helped you out? Please donate via Paypal

sinilill
Posts: 111
Joined: 02 Dec 2013 18:37

Re: Bug when launching from command line

Post by sinilill »

Yeah, I have %f quoted.

Now I downloaded a fresh copy of XY and tried it with a file path just from the cmd prompt. It WORKED, XY was running and I could enter as many file paths as I wanted and it would go to the location and select the file. But after a XY restart it DID NOT WORK anymore. I can still start XY with a file path and it works, but when XY is already running it isn't working anymore! I tried it with 3 fresh copies of XY and everytime had the same behaviour! Folder paths are always working!

Screenshot with fresh copy of XY
Image

Screenshot of my XY
Image

Looks like the last backslash from the file path is moved to the very end, so it looks like a folder path.
Both instances of XY are 15.40.0106

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

Re: Bug when launching from command line

Post by highend »

Configuration > Startup & Exit > Allow multiple instances

Disable that. Try again.
One of my scripts helped you out? Please donate via Paypal

sinilill
Posts: 111
Joined: 02 Dec 2013 18:37

Re: Bug when launching from command line

Post by sinilill »

Thanks, that solved the problem!

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

Re: Bug when launching from command line

Post by highend »

Yeah, but it's still a bug :biggrin:
One of my scripts helped you out? Please donate via Paypal

admin
Site Admin
Posts: 60567
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Bug when launching from command line

Post by admin »

Yes, but not XY's bug.

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

Re: Bug when launching from command line

Post by highend »

Which bug is it then?

A command prompt:
echo "%temp%\1.txt"
"C:\Users\Highend\AppData\Local\Temp\1.txt"
"D:\Users\Highend\Tools\XYplorer\XYplorer.exe" "%temp%\1.txt"
The running XY instance should now open that path inside a tab and select the file but with
[x] Allow multiple instances
you only get:
Location currently not available.
Highend\AppData\Local\Temp1.txt
C:\Users\
is missing
and the backslash after Temp.

If [ ] Allow multiple instances is off, the same procedure leads to a correct result.

Can't see a bug invoked through the command prompt?
One of my scripts helped you out? Please donate via Paypal

admin
Site Admin
Posts: 60567
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Bug when launching from command line

Post by admin »

Oh, now I see it too! Yes, it IS a bug. Fixing...

admin
Site Admin
Posts: 60567
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Bug when launching from command line

Post by admin »

Fixed. It was even a double bug.

- %temp% not parsed
- slash missing

Thanks!

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

Re: Bug when launching from command line

Post by highend »

For other environment variables the missing slash was fixed as well?

E.g.: %userprofile% is resolved correctly but the missing backslash after the folder messes the thing up.
One of my scripts helped you out? Please donate via Paypal

admin
Site Admin
Posts: 60567
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Bug when launching from command line

Post by admin »

Yes, all should be fixed next ver.

Post Reply