Quick way to copy tab to opposite panel?

Discussion & Support for xplorer² professional

Moderators: fgagnon, nikos, Site Mods

Post Reply
atitlan
Member
Member
Posts: 39
Joined: 2008 Dec 21, 04:29

Quick way to copy tab to opposite panel?

Post by atitlan »

The previous thread,"Quick way to Open folders in Other Panel ?", leads me to ask:

is there a command and shortcut to 'Copy Across' - that is, to clone a tab in the opposite pane? Not 'Force' (Ctrl + I), but copy as a new tab.

Thanks!
User avatar
FrizzleFry
Platinum Member
Platinum Member
Posts: 1241
Joined: 2005 Oct 16, 19:09

Post by FrizzleFry »

if you focus on a regular file then opening a tab in the opposite pane is the same a copying
atitlan
Member
Member
Posts: 39
Joined: 2008 Dec 21, 04:29

Post by atitlan »

Thanks, FrizzleFry. But I can't achieve the result I want with your method. It only works when opening a new tab in the same pane.

I'm looking to clone (Copy) a tab in the opposite pane, as though there were a corresponding menu item to 'Move across' that copied the tab to the opposite pane whilst leaving the original tab open in the originating pane.
User avatar
snakebyte
Gold Member
Gold Member
Posts: 430
Joined: 2003 May 07, 07:14
Location: Seattle
Contact:

Post by snakebyte »

I have following AutoIt3 script that does this.

Code: Select all

#NoTrayIcon 

Opt("WinTitleMatchMode", 4) 
WinActivate("classname=ATL:ExplorerFrame", "") 

;Get active pane path
$path =  ControlGetText ("classname=ATL:ExplorerFrame", "", "Edit1")

;Switch to inactive pane
Send("{tab}")

;insert a new tab
Sleep(300)
Send("^{INSERT}")

; Set focus on address bar
ControlFocus("classname=ATL:ExplorerFrame", "", "Edit1")

;Set the path  in the address bar
ControlSetText ("classname=ATL:ExplorerFrame", "", "Edit1",$path)
Send("{enter}")

;Switch back to original active pane
Send("{tab}")

Exit 
Help! I'm an AI running around in someone's universe simulator.
atitlan
Member
Member
Posts: 39
Joined: 2008 Dec 21, 04:29

Post by atitlan »

snakebyte: Many thanks! I am using MenuHack, but am new to such an AutoIt3 script. Am I correct in assuming AutoIt3 needs to be installed?

Could you post a screen capture of your User Command Properties window for running this script in xplorer²?

Grateful indeed.
User avatar
snakebyte
Gold Member
Gold Member
Posts: 430
Joined: 2003 May 07, 07:14
Location: Seattle
Contact:

Post by snakebyte »

You need to Install AutoIt3 only to create or compile scripts. Since you do not have AutoIt3 installed, you can download compiled version of this script from here and add it to your toolbar as a new user command.
Help! I'm an AI running around in someone's universe simulator.
atitlan
Member
Member
Posts: 39
Joined: 2008 Dec 21, 04:29

Post by atitlan »

Thanks again!

This is the line I have placed in 'Description' of User Command Properties (corresponding to the location of your compiled script on my system):

> "C:\Files\xplorer2_Commands\DuplicateActiveTabToInactivePaneInNewTab.exe"

Unexpected result - a new tab opens in the opposite pane, but to a random subfolder of the adjacent tab in that pane, completely unrelated to the originating tab and pane.

Am I referencing the script incorrectly?
User avatar
snakebyte
Gold Member
Gold Member
Posts: 430
Joined: 2003 May 07, 07:14
Location: Seattle
Contact:

Post by snakebyte »

You are using the script the right way. Do you get the same behavior in multiple tries? You may require to fine tune this script by inserting additional sleep statements or by increasing the existing sleep duration.

How many tabs are open in each pane on your machine? Could you close all the tabs in both the panes and see if this script works for you? Could you try and find the pattern of the new folder that this script opens?
Help! I'm an AI running around in someone's universe simulator.
Gandolf
Gold Member
Gold Member
Posts: 470
Joined: 2004 Jun 12, 10:47

Post by Gandolf »

This is an AutoHotkey script I used to do the same thing.

Code: Select all

SendInput, {TAB}	;switch to other pane
WinWaitActive, xplorer² - 
SendInput, {CTRLDOWN}{INS}{CTRLUP}	;open new tab
WinWaitActive, xplorer² - 
SendInput, {TAB}{CTRLDOWN}i{CTRLUP}	;switch back to original pane and open the same folder in the other pane
Post Reply