Page 1 of 1

Using script command to OPEN PATH does not seem to open TAB

Posted: 19 Mar 2022 14:34
by star

Code: Select all

$exec("C:\Tools\XYplorer\XYplorer.exe" /feed=|::perm $$P_EVERYTHING_FOLDER = "%1"; load "Everything.xys";|)
Image

Code: Select all

perm $P_EVERYTHING_FOLDER;

    if (exists($P_EVERYTHING_FOLDER) == 2) {
        tab("new", $P_EVERYTHING_FOLDER);
    }
    unset $P_EVERYTHING_FOLDER;

Image

This script does not work on OPEN PATH, only on OPEN folders. How to solve it ?

Image

If don't change openpath

Image

It opens in the old TAB, not the new TAB

Re: Using script command to OPEN PATH does not seem to open TAB

Posted: 19 Mar 2022 14:47
by Norn
Configuration | Other | Shell Integration | Default File Manager | XYplorer is default file manager?
Configuration | General | Startup & Exit | Open command line start path in new tab...

Re: Using script command to OPEN PATH does not seem to open TAB

Posted: 19 Mar 2022 14:55
by highend
Because it must be treated differently?

Code: Select all

    perm $P_EVERYTHING_FOLDER;

    if (exists($P_EVERYTHING_FOLDER) == 1) {
        tab("new", gpc($P_EVERYTHING_FOLDER, "path"));
        selectitems gpc($P_EVERYTHING_FOLDER, "file");
        sel "+0";
        focus;

    } elseif (exists($P_EVERYTHING_FOLDER) == 2) {
        tab("new", $P_EVERYTHING_FOLDER);
    }
    unset $P_EVERYTHING_FOLDER;

Re: Using script command to OPEN PATH does not seem to open TAB

Posted: 20 Mar 2022 05:03
by star
Norn wrote: ↑19 Mar 2022 14:47 Configuration | Other | Shell Integration | Default File Manager | XYplorer is default file manager?
Configuration | General | Startup & Exit | Open command line start path in new tab...
A very effective solution! You're great!

Re: Using script command to OPEN PATH does not seem to open TAB

Posted: 20 Mar 2022 05:16
by star
highend wrote: ↑19 Mar 2022 14:55 Because it must be treated differently?

Code: Select all

    perm $P_EVERYTHING_FOLDER;

    if (exists($P_EVERYTHING_FOLDER) == 1) {
        tab("new", gpc($P_EVERYTHING_FOLDER, "path"));
        selectitems gpc($P_EVERYTHING_FOLDER, "file");
        sel "+0";
        focus;

    } elseif (exists($P_EVERYTHING_FOLDER) == 2) {
        tab("new", $P_EVERYTHING_FOLDER);
    }
    unset $P_EVERYTHING_FOLDER;
Its effects are as follows:

Image

It opens in the old TAB, not the new TAB.

Fortunately, there was an effective solution on the second floor, but I really appreciate your help😃

Re: Using script command to OPEN PATH does not seem to open TAB

Posted: 20 Mar 2022 05:27
by jupe
superspeed GIF, so easy to follow. 🙃