Thanks!
^ Flat View Sample?
-
Zardoz2293
- Posts: 594
- Joined: 09 Nov 2011 20:20
- Location: USA
^ Flat View Sample?
Would appreciate a sample script call using the "Flat View" mode. I'm currently using "folderreport" and I'm sure I'm on the wrong track.
Thanks!
Thanks!
Last edited by Zardoz2293 on 12 Feb 2012 21:44, edited 1 time in total.
-
admin
- Site Admin
- Posts: 65174
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: Flat View Sample?
If you want to turn on Flat View via scripting:
Code: Select all
goto "? /:flat";FAQ | XY News RSS | XY X
Re: Flat View Sample?
You can also dial:
Code: Select all
#311; //View | Tab | Views | Flat View-
Zardoz2293
- Posts: 594
- Joined: 09 Nov 2011 20:20
- Location: USA
Re: Flat View Sample?
Sorry gentlemen, I'm just not getting it. I've reviewed the scripting stuff, but I just don't see how to get a BV (Branch View) into a variable. I don't want any of my visual / displayed tabs views / trees / lists to be modified. When I saw some of the output Don showed with the BV and the sorting capability I knew that was what I needed. I want to utilize native XY capability over doing manual coding to achieve the desired effect.
Currently, I have something like (example is overly simplified):
Which returns (totally useless to me):
as it needs to be like the result set below:
I don't find or I'm not recognizing the information within the online help file. Under "Scripting Command Reference", 'branch' is only referenced under "box".
Does getting a BV into a variable take more than a single like of code? Is there an example of this?
I'm totally lost. Thanks for the feedback.
Currently, I have something like (example is overly simplified):
Code: Select all
//<curpath> == "F:\XY.Test\Test\PDF\v3"
$FileList = folderreport("items", "r", "<curpath>", "r", , "|");Code: Select all
F:\XY.Test\Test\PDF\v3 <DIR>
F:\XY.Test\Test\PDF\v3\v3.10 (2005-10-03) <DIR>
F:\XY.Test\Test\PDF\v3\v3.10 (2005-10-03)\Install.exe
F:\XY.Test\Test\PDF\v3\v3.20 (2005-11-05) <DIR>
F:\XY.Test\Test\PDF\v3\v3.20 (2005-11-05)\Install.exe
F:\XY.Test\Test\PDF\v3\v3.64 (2010-12-10) <DIR>
F:\XY.Test\Test\PDF\v3\v3.64 (2010-12-10)\Install.exeCode: Select all
F:\XY.Test\Test\PDF\v3\v3.10 (2005-10-03)\Install.exe
F:\XY.Test\Test\PDF\v3\v3.10 (2005-10-03) <DIR>
F:\XY.Test\Test\PDF\v3\v3.20 (2005-11-05)\Install.exe
F:\XY.Test\Test\PDF\v3\v3.20 (2005-11-05) <DIR>
F:\XY.Test\Test\PDF\v3\v3.64 (2010-12-10)\Install.exe
F:\XY.Test\Test\PDF\v3\v3.64 (2010-12-10) <DIR>
F:\XY.Test\Test\PDF\v3 <DIR>Does getting a BV into a variable take more than a single like of code? Is there an example of this?
I'm totally lost. Thanks for the feedback.
Last edited by Zardoz2293 on 30 Jan 2012 22:16, edited 1 time in total.
-
admin
- Site Admin
- Posts: 65174
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: Flat View Sample?
This will give you the idea:
Code: Select all
goto "E:\Test\a\? /:flat";FAQ | XY News RSS | XY X
-
Zardoz2293
- Posts: 594
- Joined: 09 Nov 2011 20:20
- Location: USA
Re: Flat View Sample?
I'm getting some odd effects, but I'll discuss that later.admin wrote:This will give you the idea:Code: Select all
goto "E:\Test\a\? /:flat";
Is there any native scripting method to
Thanks!Zardoz2293 wrote:Default: Order By FOLDERS, FILERequired/Needed: Order By FILES, FOLDERSCode: Select all
F:\XY.Test\Test\PDF\v3 <DIR> F:\XY.Test\Test\PDF\v3\v3.10 (2005-10-03) <DIR> F:\XY.Test\Test\PDF\v3\v3.10 (2005-10-03)\Install.exeCode: Select all
F:\XY.Test\Test\PDF\v3\v3.64 (2010-12-10)\Install.exe F:\XY.Test\Test\PDF\v3\v3.64 (2010-12-10) <DIR> F:\XY.Test\Test\PDF\v3 <DIR>
Last edited by Zardoz2293 on 31 Jan 2012 01:28, edited 3 times in total.
-
serendipity
- Posts: 3360
- Joined: 07 May 2007 18:14
- Location: NJ/NY
Re: Flat View Sample?
Closest you can get is:Zardoz2293 wrote:I'm getting some odd effects, but I'll discuss that later.admin wrote:This will give you the idea:Code: Select all
goto "E:\Test\a\? /:flat";
Is there any native scripting method to "Order By FILES, FOLDERS" rather than the default "Order By FOLDERS, FILES"?
Thanks!Zardoz2293 wrote:Default:Required:Code: Select all
F:\XY.Test\Test\PDF\v3 F:\XY.Test\Test\PDF\v3\v3.10 (2005-10-03) F:\XY.Test\Test\PDF\v3\v3.10 (2005-10-03)\Install.exeCode: Select all
F:\XY.Test\Test\PDF\v3\v3.64 (2010-12-10)\Install.exe F:\XY.Test\Test\PDF\v3\v3.64 (2010-12-10) F:\XY.Test\Test\PDF\v3
Config>General>Sorting> and uncheck Keep folders on top. Then sort descending.
-
Zardoz2293
- Posts: 594
- Joined: 09 Nov 2011 20:20
- Location: USA
Re: Flat View Sample?
So it can't be done in scripting?serendipity wrote:Closest you can get is:
Config>General>Sorting> and uncheck Keep folders on top. Then sort descending.
-
serendipity
- Posts: 3360
- Joined: 07 May 2007 18:14
- Location: NJ/NY
Re: Flat View Sample?
AFAIK, no.Zardoz2293 wrote:So it can't be done in scripting?serendipity wrote:Closest you can get is:
Config>General>Sorting> and uncheck Keep folders on top. Then sort descending.
Re: Flat View Sample?
@Zardoz2293: Don was asking for command ID's to be added today, in this thread.
-
Zardoz2293
- Posts: 594
- Joined: 09 Nov 2011 20:20
- Location: USA
Re: Flat View Sample?
My comment here is not related to this topic, but thanks for the location of the "Keep folders on top" information -- I've been looking for it but wasn't sure of the name or where to find. Thanks!serendipity wrote:Config>General>Sorting> and uncheck Keep folders on top. Then sort descending.
-
Zardoz2293
- Posts: 594
- Joined: 09 Nov 2011 20:20
- Location: USA
Re: Flat View Sample?
AFAIK the above has no effect on the order of the folders and files in a Branch View.serendipity wrote:Closest you can get is:
Config>General>Sorting> and uncheck Keep folders on top. Then sort descending.
-
Zardoz2293
- Posts: 594
- Joined: 09 Nov 2011 20:20
- Location: USA
Re: Flat View Sample?
I haven't got the hang of the whole command ID thing, so I don't understand the impact of what this means.nas8e9 wrote:@Zardoz2293: Don was asking for command ID's to be added today, in this thread.
Re: Flat View Sample?
From the help file:Zardoz2293 wrote:I haven't got the hang of the whole command ID thing, so I don't understand the impact of what this means.nas8e9 wrote:@Zardoz2293: Don was asking for command ID's to be added today, in this thread.
However, I was barking up the wrong tree: XYplorer's scripting has a setting command:Scripting by Numbers
In XYplorer almost every function has a fixed number, the function ID, by which it can be referred to in a script. ID #1026 happens to refer to "Miscellaneous / Find Files / Open Find Files and Reset". Open the Customize Keyboard Shortcuts dialog (menu Tools) and find this function in category Miscellaneous. At the bottom of the dialog you'll see a button showing the function's ID. Clicking this button will copy the function's ID to the clipboard, making it easy to use it in a script.
You can execute almost any function in XY in a script by referring to its function ID. E.g. #230 will pop up the submenu "New" of menu Edit.
... meaning adding the following to your script:setting
Alter some of XYplorer's user settings, temporarily or permanently. Typically used in order to ensure the expected execution of a script, which might depend on certain settings.
Syntax
setting name, [value (1|0|r)], [permanent (p)]
name
[Required] One of the following (case insensitive):
...
SortFoldersApart: Sort folders apart
Code: Select all
setting SortFoldersApart, 0;-
Zardoz2293
- Posts: 594
- Joined: 09 Nov 2011 20:20
- Location: USA
Re: Flat View Sample?
I'm not have success with the:
However, the problem is, I need all the files processed in each folder before the folder containing those files are renamed. The current order of the files/folders works only if you approach processing from the end -->start of the result set. However, the foreach only processes from from the start-->end. Using a "while" is not as elegant and risk free as a foreach. I don't see that PHP reverse array elements and I don't want to perform a scripted reverse of the string array to be able to use the foreach. Therefore the inferior while will have to be used, unless there is a superior alternative I'm not aware of.
What are your thoughts?
Code: Select all
setting SortFoldersApart, 0;What are your thoughts?
XYplorer Beta Club