Get Dual Pane mode?
Get Dual Pane mode?
Is it possible to return the current mode in scripting? Is dual pane toggled on or off? I've tried returning the get("Item",1) commands. But even if dual pane is toggled off, Pane 2 still returns the path.
I'm looking to script turning on Dual Pane if it's off and setting both paths.
I know toggling it is #800; //Toggle Dual Panes
But before toggling, I need to know if it's on or off. Else if I #800; I may be turning it off.
I'm looking to script turning on Dual Pane if it's off and setting both paths.
I know toggling it is #800; //Toggle Dual Panes
But before toggling, I need to know if it's on or off. Else if I #800; I may be turning it off.
-
admin
- Site Admin
- Posts: 65338
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: Get Dual Pane mode?
Hi and welcome,
I added something experimentally. In the next BETA try this:
I added something experimentally. In the next BETA try this:
Code: Select all
echo state(800);FAQ | XY News RSS | XY X
-
admin
- Site Admin
- Posts: 65338
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: Get Dual Pane mode?
Forget this, I got something better:admin wrote:Hi and welcome,
I added something experimentally. In the next BETA try this:Code: Select all
echo state(800);
Code: Select all
text get("#800", "DP", "SP");FAQ | XY News RSS | XY X
Re: Get Dual Pane mode?
Works Perfectly! You rock!admin wrote:Forget this, I got something better:Code: Select all
text get("#800", "DP", "SP");
Code: Select all
$p = get("#800", "DP", "SP");
if $p == "SP" {
#800; //Toggle Dual Panes
}-
admin
- Site Admin
- Posts: 65338
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: Get Dual Pane mode?
Tip: If you don't need the labels for display you can also use this shorter version:
Code: Select all
if get("#800") == "1" {
#800; //Toggle Dual Panes
}FAQ | XY News RSS | XY X
Re: Get Dual Pane mode?
Nice... you're right. I didn't need the defined variable. I love efficient code.admin wrote:Tip: If you don't need the labels for display you can also use this shorter version:Code: Select all
if get("#800") == "1" { #800; //Toggle Dual Panes }
-
admin
- Site Admin
- Posts: 65338
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: Get Dual Pane mode?
Whoops, I showed you bad (but working) syntax. The expression after if *should* be in parentheses:
Code: Select all
if (get("#800") == "1") {
#800; //Toggle Dual Panes
}FAQ | XY News RSS | XY X
Re: Get Dual Pane mode?
Mine was working without them. But single pane = "0", dual pane = "1". I wanted to insure dual pane was active.admin wrote:Whoops, I showed you bad (but working) syntax. The expression after if *should* be in parentheses:Code: Select all
if (get("#800") == "1") { #800; //Toggle Dual Panes }
Last edited by EnjoyRC on 09 Nov 2010 14:42, edited 1 time in total.
Re: Get Dual Pane mode?
If only we had a not-operator then you could make it:If only...

Code: Select all
if (! get('#800')) {
#800;
}-
admin
- Site Admin
- Posts: 65338
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: Get Dual Pane mode?
Aaah, sure!EnjoyRC wrote:Mine was working without them. But single pane = "0", dual pane = "1". I wanted to insure dual pane was active.admin wrote:Whoops, I showed you bad (but working) syntax. The expression after if *should* be in parentheses:Code: Select all
if (get("#800") == "1") { #800; //Toggle Dual Panes }
FAQ | XY News RSS | XY X
Re: Get Dual Pane mode?
MakeCoffee;admin wrote:Aaah, sure!![]()
(Didn't have much sleep tonite.)
-
admin
- Site Admin
- Posts: 65338
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: Get Dual Pane mode?
Try next version.TheQwerty wrote:If only we had a not-operator then you could make it:If only...Code: Select all
if (! get('#800')) { #800; }![]()
PS: All this should work in 9.70.0005... looks like I got it.
Code: Select all
if (!get('#800')) {
#800;
}
if (! get('#800')) {
#800;
}
if (not get('#800')) {
#800;
}
if (not not not get('#800')) {
#800;
}
FAQ | XY News RSS | XY X
Re: Get Dual Pane mode?
How cool!admin wrote:PS: All this should work in 9.70.0005... looks like I got it.
-
j_c_hallgren
- XY Blog Master
- Posts: 5826
- Joined: 02 Jan 2006 19:34
- Location: So. Chatham MA/Clearwater FL
- Contact:
Re: Get Dual Pane mode?
That's why we LOVE Don and XY SO much! Sounds like a good quote for Don to use on site if possible.EnjoyRC wrote:By the way, thank you for your ultra-quick responses. What a great product, and seeing that support is awesome for XYplorer makes me that much more confident in my purchase!
Still spending WAY TOO much time here! But it's such a pleasure helping XY be a treasure!
(XP on laptop with touchpad and thus NO mouse!) Using latest beta vers when possible.
(XP on laptop with touchpad and thus NO mouse!) Using latest beta vers when possible.
Re: Get Dual Pane mode?
I had expected that this would also work:admin wrote:Try next version.TheQwerty wrote:If only we had a not-operator then you could make it:If only...Code: Select all
if (! get('#800')) { #800; }![]()
(No time to document it...)
PS: All this should work in 9.70.0005... looks like I got it.![]()
Code: Select all
$a = 'a';
if (! "$a" Like "") {
echo 'hi';
}Code: Select all
$a = 'a';
if (! ("$a" Like "")) {
echo 'hi';
}
XYplorer Beta Club