Page 1 of 1

Have problem with load and tabset

Posted: 25 Dec 2011 00:10
by Borut
Let $TabsetBase be a permanent variable already set to an existing folder.

Then the following scripting command will work as expected:

Code: Select all

tabset("open", "$TabsetBase as: $TabsetBase\<get pane>");
If, however, I prepare a script file Tabsets.xys with the following content:

Code: Select all

"Open Tabset : opentabset"
  tabset("open", "$TabsetBase as: $TabsetBase\<get pane>");
and define "On right-click" of the user button to be:

Code: Select all

 load "Tabsets.xys", "opentabset"
then this seems not to work. Apparently $TabsetBase is not being resolved in that case - I am getting the error message:
"Path not found: C:\_PortableProgramFiles\xyplorer\Data\Panes\$TabsetBase\"

What am I doing wrong? (I additionally tried pronouncing $TabsetBase a global variable, but that did not help.)

Re: Have problem with load and tabset

Posted: 25 Dec 2011 00:54
by PeterH
If $TabsetBase is set in another script, it must be defined there as global, too. (Before setting it...)

And, of course, in the refering script, before referencing.

I can't see from your description, if you did it this way.

Re: Have problem with load and tabset

Posted: 25 Dec 2011 01:06
by Borut
PeterH wrote:And, of course, in the refering script, before referencing.
Thank you Peter! :D This seems to have been it. Interestingly enough, this seems to have worked before, when I had them all defined directly with the user button. As soon as I defined them in a .xys-file and started using load in user button, this apparently became important.

BTW, had a lot of fun now viewing the "photoshopic" reviews of XY by FeatureCreep. "Mouse Down Blow Up"... ROTFL :mrgreen:

Re: Have problem with load and tabset

Posted: 25 Dec 2011 01:11
by PeterH
Glad if I could help.

And glad I could read FeatureCreep's "photoshopic" reviews in the meantime. Enjoyed it :D

And by the way: Merry Christmas to everyone! Have some fine days!

Re: Have problem with load and tabset

Posted: 25 Dec 2011 06:32
by j_c_hallgren
Borut wrote:BTW, had a lot of fun now viewing the "photoshopic" reviews of XY by FeatureCreep. "Mouse Down Blow Up"... ROTFL :mrgreen:
Yup! Those are some GREAT images! I hope that Don can make use of some of them on the actual XY site.