Create New Folder and not lose focus of current folder

Features wanted...
Post Reply
m48tx
Posts: 318
Joined: 07 May 2010 18:07
Location: Windows 11 25H2, Scaling 100%

Create New Folder and not lose focus of current folder

Post by m48tx »

Please. Please. Could we have the ability to create one or more new folders in some other folder without losing focus of current folder?

Or, does this ability exist currently?

Cheers,
Gary

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

Re: Create New Folder and not lose focus of current folder

Post by highend »

?

The new folder needs a name (which is normally not "New Folder") so it's normal that the focus changes.

Just use a script?

Code: Select all

    $curItem = "<curitem>";
    new(input("Enter folder name...", , "New folder", , , 200, 150), "dir");
    selectitems $curItem;
One of my scripts helped you out? Please donate via Paypal

m48tx
Posts: 318
Joined: 07 May 2010 18:07
Location: Windows 11 25H2, Scaling 100%

Re: Create New Folder and not lose focus of current folder

Post by m48tx »

highend wrote:?

The new folder needs a name (which is normally not "New Folder") so it's normal that the focus changes.

Just use a script?

Code: Select all

    $curItem = "<curitem>";
    new(input("Enter folder name...", , "New folder", , , 200, 150), "dir");
    selectitems $curItem;

OK. I did not explain my request well. I have an existing folder open so its content is displayed in the List area. I want to move some of the files to a new folder that needs to be created. I would like to right click on the parent folder in the Tree to create the new folder without losing the position in the List area. So, the new folder is created and I still have focus on the files in the List. Directory Opus does this and I find it very useful. XYP creates the new folder and then selects the new folder so I lose focus on the current List files.

I created your script but it accomplishes exactly the same thing XYP does by default. Am I missing something?

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

Re: Create New Folder and not lose focus of current folder

Post by highend »

"without losing focus of current folder?"
That's why the script set the selection back to the last selected item.

And no, this is not what XY does by default (at least not, when a single new folder is created).

Code: Select all

    $selItems = "<selitems |>";
    new(input("Enter folder name...", , "New folder", , , 200, 150), "dir");
    selectitems $selItems;
One of my scripts helped you out? Please donate via Paypal

m48tx
Posts: 318
Joined: 07 May 2010 18:07
Location: Windows 11 25H2, Scaling 100%

Re: Create New Folder and not lose focus of current folder

Post by m48tx »

Thank you very much for your response and the script.

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

Re: Create New Folder and not lose focus of current folder

Post by highend »

You could have used #243; instead as well (allows the creation of multiple folders at once without removing the current selection) but instead of just hitting ENTER to confirm that dialog you'd need to use Ctrl + Enter instead.
One of my scripts helped you out? Please donate via Paypal

m48tx
Posts: 318
Joined: 07 May 2010 18:07
Location: Windows 11 25H2, Scaling 100%

Re: Create New Folder and not lose focus of current folder

Post by m48tx »

Please forgive my lack of knowledge. What is "#243;"?

Update: Oops, found it. Command ID. Thanks!

Luigi
Posts: 57
Joined: 01 Sep 2011 00:41

Re: Create New Folder and not lose focus of current folder

Post by Luigi »

Admin can you add a flag for "don't change focus of selected items" (e.g. selitem, selitems, curitem) for new()?

Post Reply