to select several files in the dialog box open, but it is impossible, isn't it?

Hi forum,

File and folder objects have a openDlg() method. The first also has the multiSelect parameter, it is not.

I wish I could have also for the folder so that I can ctrl/shift select several folders instead of picking up a folder and all its subfolders processing.

Maybe I'm missing something obvious or there is a solution to such a dialogue box.

Kind regards

Kasyan

As suggested, an approach as possible:

Folder.prototype.selectMultipleDialog = function (prompt,multiselect){
  var w = new Window('dialog','MultipleSelectDialog'),
  st,
  ls,
  btnGp,
    koBtn,
    okBtn,
    folderFilter = function(f){
        return (f instanceof Folder)
    },
    u,
    folders = this.getFiles(folderFilter),
    getFolderNames = function(foldersObjectArray){
        var n = foldersObjectArray.length,
        namesArray = [];
        while ( n--){
            namesArray[n] = decodeURI(foldersObjectArray[n].name);
        }
        return namesArray;
    },
    folderListItems = getFolderNames(folders),
    n = 0;

    st = w.add('statictext',u,prompt);
    ls = w.add('listbox',undefined, folderListItems, {multiselect:multiselect} );

    btnGp = w.add('group');

    koBtn = btnGp.add('button',u,'Cancel');
    okBtn = btnGp.add('button',u,'Select');

    koBtn.onClick = function(){
  w.close(0);
  }

  okBtn.onClick = function(){
  w.close(1);
  }

    ls.onChange = function() {
        okBtn.enabled = ls.selection!==null;
    }

    w.preferredSize.width = 450;
    w.alignChildren = ["fill","top"];
    ls.preferredSize.height = 200;
    btnGp.alignChildren = ["right","top"];

  okBtn.enabled = false;

    if ( w.show()==1 ){
  if ( ls.selection instanceof Array ) {
  n = ls.selection.length;
            while ( n-- ) folders[ls.selection[n].index].execute();
  }
  else {
  folders[ls.selection.index].execute();
  }
  }
}

var fo = Folder.desktop;
fo.selectMultipleDialog("test", true)

HTH

Loïc

www.ozalto.com

Tags: InDesign

Similar Questions

  • How can I get a "Détails" view - as the default - when you download a file, in the dialog box "enter the name of the file to save on...» » ?

    When I get an attachment to an email (using Zimbra Imail, Firefox, Windows XP Pro) and I click on it and select 'Download', I get the dialog box "enter the name of the file to save on...» "(because I already have the option"always ask me where to save files. "But the view of default file always in a 'list '. At least recently. I don't remember it always does this. In any case, I want the value default to a 'Détails' view, in ascending order, I can find then things so much faster that way. (I often use the 'Update' tab to bring up, the latest version of a file.) I know that I can go to the Menu 'view' icon and select 'Détails', but whenever I go in a sub-folder in this dialog box, I have to do this all over again and it wastes a lot of time and attention.

    I did some research on the internet but have not found a way to solve this problem.

    Try this:

    a. open my documents, press the alt key.

    b. click on Tools. Click on folder options.

    c. click on the view tab and select Reset and check records.

  • How can I configure the dialog box open to show details by default?

    By default, the open dialog box always opens in list view. I want that it is displayed in the details view and I want to rearrange the columns as well.

    Is it possible to change the default layout of the open dialog boxes in Windows? I expected to work like the Windows Explorer, but it does not work.

    It should do, in fact.  I just tested here with Notepad.

    1. Open Notepad and click file/open
    2. Change the style or the size of the icons (I put it "Extra large icons")
    3. Clicked on cancel
    4. File/open again and I have observed that the icons were always great like last time.  I changed them will be list.
    5. I closed and opened the dialog box "Open" once more and has pointed out that the icons are still in list view.

    Given this test, I think that it must be based on the program that you are using.

  • Unable to select the file in the dialog box in the Sierra

    I'm unable to select an image file in the "save for Web" in the finder window "save under" in Photoshop CC running on the Sierra.

    There are times where I need to save a new image using a similar name by selecting the existing file, which matches the name in the dialog box "save under".

    The use of Photoshop CC in Sierra I am unable to do so due to the inability to select the existing files in the Save-as the finder window.

    I thought at first that was Adobe, but later, I noticed that I can not save for web browsers and other programs. I installed the beta updates on Sierra, but also which did not set. I hope be fixed so I can move on to Sierra. It was not such a problem in previous versions.

    Unfortunately, your discovery is correct. I just met for the first time. I was shocked, but apparently it will work in list view. View miniature not a reason any.

  • Why can't I get a glimpse of the indd files in the dialog box to open InDesign?

    Hi all

    It is unfortunate that Adobe does not add a plugin to display a preview of any Adobe source file in Windows Explorer (I mean, except for the PDF but I think that Microsoft did this).

    But I think it's ridiculous that I can't preview the source .indd inside the dialog box to open InDesign files. He says just, "no preview available". I am sure that this failure is related to what Windows can preview... again, not a good excuse!

    It is also the same problem in Illustrator and Photoshop... or program Adobe can get a glimpse of their own file format!

    WHY?  OR how can I fix this?

    [UPDATE: SageThumbs |] [SourceForge.net seems to partially work on several Photoshop files (works reasonably well as long as I limit the file size to 70 mb), it doesn't seem to work with Illustrator files (despite the claim), and it does not work on InDesign.]

    Yet the question remains: why Adobe is not taking responsibility for this?

    I think that for the dialog open regularly, Adobe wants to use operation

    Open the file integrated system of dialogue, so that users are familiar with it.

    and also if they can use the peculiarities of their OS (Windows vs

    Mac have different habits).

    And to solve your problem, they created Bridge (and even Mini Bridge).

    He could theoretically get into the habit to use to open the files,

    That is, instead of file > open it just click on the bridge icon.

  • Adobe application support files of missing files in the dialog box?

    I get a dialog box when I open PS CC 2015 that a file (s) is missing from the Adobe Application support folder is missing. I click ok and PS CC 2015 seems to work very well. This is a new message that just popped up. The dialog box also tells me to reinstall the PS... Comments?

    I tried again. I uninstalled the CC PS, then leave CC. reinstalled the link CC and CC PS, 2015. Who took care of the problem!

  • Generate the log file for the dialog box

    Hi all


    I'm generating information for the dialog box as a .txt log file format. That means that if the box is checked, the log file will be give ' checkbox1 - 01.»   Check the report, sizes against the information on tickets and slug jobs"is checked


    If the checkbox is not checked, the log file will be give ' checkbox1 - 01.»   Check the report, sizes against ticket and slug information on employment"is not checked


    and also the entry "myText2" also needs to generate the log file


    Can someone help on this... Help would be appreciated!



    var l is new window ('dialogue');.

    myGroup1 var = w.add ("panel", undefined, ' P & & G check the list ');

    myGroup1.alignChildren = 'left ';

    CheckBox1 var = myGroup1.add ("checkbox", not defined, '01.   (Check the ratio, size against the information on tickets and slug jobs");

    CheckBox2 var = myGroup1.add ("checkbox", not defined, '02.   "" "Check images are linked");

    var checkbox3 = myGroup1.add ("checkbox", not defined, '03.   Visually check the progress of KV/model/CP images");

    var checkbox4 = myGroup1.add ("checkbox", not defined, '04.   Visually check the progress of other elements such as Logo and bottle");

    var checkbox5 = myGroup1.add ("checkbox", not defined, '05.   Check the positioning of the markup language");

    var checkbox6 = myGroup1.add ("checkbox", not defined, '06.   Ensure that all measures are calculated Live based area");

    var checkbox7 = myGroup1.add ("checkbox", not defined, '07.   After that the resizing of the picture KV frame open to cut and bleed");

    var checkbox8 = myGroup1.add ("checkbox", not defined, '08.   Complete Magenta if there is insufficient image');

    var checkbox9 = myGroup1.add ("checkbox", not defined, '09.   ("To ensure that the document's bleed, crop gutter and slug information brands ');

    var checkbox10 = myGroup1.add ("checkbox", not defined, '10.   Make sure that the final work is updated on the server");

    var checkbox11 = myGroup1.add ("checkbox", not defined, '11.   ("Enter time cmd");

    var myGroup2 = w.add ('panel', undefined, 'The operator name');

    var myText2 = myGroup2.add ("edittext", undefined, "");

    myText2.characters = 25;

    myGroup2.orientation = 'left ';

    var buttons = w.add ("group");

    Buttons.Add ('button', undefined, 'Export to PDF', {name: 'ok'});

    Buttons.Add ('button', undefined, 'Cancel');

    w.Show ();

    ~ group();

    ~ If (myGroup1.alignChildren.value! = true) {}

    ~ alert ('yes')

    //~ }


    myDoc = app.activeDocument;

    w = [];


    DESCRIPTION: Make a TXT file

    myDoc = app.activeDocument;

    Log1 = makeLogFile (app.activeDocument.name.split('.') ([0], myDoc, true);

    log (log1, app.activeDocument.name);

    ~ log2 = makeLogFile ("test", myDoc, false);

    ~ Journal (log2, "Text file log base 2");

    Log1. Execute();

    ~ log2.execute ();

    function makeLogFile (aName, aDoc, deleteIt) {}

    var logLoc; path to the folder that will contain the log file

    try {}

    logLoc = aDoc.filePath;

    } catch (e) {}

    logLoc = getmyDoc (). parent.fsName

    }

    var queue = aFile (logLoc + "/" + name + ".txt");

    If {(deleteIt)

    aFile.remove ();

    return aFile;

    }

    var n = 1;

    so that {(aFile.exists)

    aFile = File (logLoc + "/" + String (n) + ".txt" aName);

    n ++

    }

    return aFile

    }

    function getScriptPath() {}

    try {}

    Return app.activeScript;

    } catch (e) {}

    Return File (e.fileName);

    }

    }

    function log (aFile, message) {}

    var today = new Date();

    If (! aFile.exists) {}

    do the new log file

    aFile.open ("w");

    aFile.write (String (today) + "\n");

    aFile.close ();

    }

    }

    function log (aFile, message) {}

    var text = o;

    If (! aFile.exists) {}

    do the new log file

    aFile.open ("w");

    aFile.write (message + "\n" + "\n" + String (w) + "\n");

    aFile.close ();

    }

    ~ aFile.open ("e");

    ~ aFile.seek (0.2);

    ~ aFile.write ("\n" + message);

    ~ aFile.close ();

    }

    myDoc.close (SaveOptions.no);

    Thanks in advance

    Steve

    Hi Steve,.

    There are some errors in your code.

    1. function 'getmyDoc' is used, but not created.
    2. fucntion 'getScriptPath' is created but not used. (In any case, this will not give you error)
    3. function 'journal' has defined two times with the same length of the parameter.

    etc...

    Here, I have modified your code. Try this.

    var w = new Window ("dialog");
    var myGroup1 = w.add('panel', undefined, 'P&&G Check List');
    myGroup1.alignChildren = "left";
    var checkbox1 = myGroup1.add ("checkbox", undefined, "  01.  Check the ratio, sizes against job ticket and slug information");
    var checkbox2 = myGroup1.add ("checkbox", undefined, "  02.  Check images are linked");
    var checkbox3 = myGroup1.add ("checkbox", undefined, "  03.  Visually check the progression of KV/Model/CP images");
    var checkbox4 = myGroup1.add ("checkbox", undefined, "  04.  Visually check the progression of other elements like Logo and Bottle");
    var checkbox5 = myGroup1.add ("checkbox", undefined, "  05.  Check the placement of Language Tagging");
    var checkbox6 = myGroup1.add ("checkbox", undefined, "  06.  Ensure that all measurements are calculated based on Live area");
    var checkbox7 = myGroup1.add ("checkbox", undefined, "  07.  After resizing the KV image frame opened up to trim and bleed");
    var checkbox8 = myGroup1.add ("checkbox", undefined, "  08.  Fill Magenta if there is inadequate image");
    var checkbox9 = myGroup1.add ("checkbox", undefined, "  09.  Ensure the document has bleed, crop marks, gutter marks and slug information");
    var checkbox10 = myGroup1.add ("checkbox", undefined, "  10.  Ensure the final artwork is updated in the Server");
    var checkbox11 = myGroup1.add ("checkbox", undefined, "  11.  Enter time in CMD");
    var myGroup2 = w.add('panel', undefined, ' Operator Name');
    var myText2 = myGroup2.add("edittext", undefined, "");
    myText2.characters = 25;
    myGroup2.orientation = "left";
    var buttons = w.add ("group");
    buttons.add ("button", undefined, "Export PDF", {name: "ok"});
    buttons.add ("button", undefined, "Cancel");
    w.show ();
    myDoc = app.activeDocument;
    log1 = makeLogFile(app.activeDocument.name.split('.')[0], myDoc, true);
    log(log1, app.activeDocument.name);
    log1.execute();
    function makeLogFile(aName, aDoc, deleteIt)
    {
        var logLoc = "";
        try
        {
            logLoc = aDoc.filePath;
            } catch (e) {}
        var aFile = File(logLoc + "/" + aName + ".txt");
        var n = 1;
        while (aFile.exists)
        {
            aFile = File(logLoc + "/" + aName + String(n) + ".txt");
            n++;
            }
        return aFile
        }
    function log(aFile, message)
    {
        var text = w;
        var rep = "";
        if (!aFile.exists)
        {
            aFile.open("w");
            var today = new Date();
            rep += String(today) + "\n";
            rep += message + "\n" + "\n\n";
            for(var i =0;i
    

    Kind regards

    Cognet

  • Area of the dialog box open in Apex 5

    Apex 5.0

    Firefox

    I'm playing with Apex 5 and I wanted to open a dialogue on the click of a button

    Created a region with a region called dialogue region dialog box template

    Created a button called OPEN

    Created a dynamic of Action

    Event: click on

    Selection type: button

    Button: OPEN

    Action: show

    Selection type: region

    Region: Region of dialogue

    When I open the page in the area of the dialog box is not displayed as expected.

    When I click the button nothing happens

    Gus

    Do not know if Oracle people want the articles published here on 5 APEX, you COULD add this to their comments that you can access in your workspace...

    Thank you

    Tony Miller
    Software LuvMuffin
    Ruckersville, WILL

  • The mouse pointer jump at the top of the screen when the dialog box opens

    In the last few weeks my mouse pointer jumps sometimes extreme high (left side) of the FF browser window. Only happens in FF, Chrome or IE or any other application from Ms. The mouse to update drivers fees Reloaded, switched mouses, USB switch, ports switched to a mouse not MS - all to nothing does.

    "It seems to happen most often when I mouse ' snap to" feature is turned on and that the pointer automatically moves to the default button in the dialog box.

    This unique disability FF to hide the pointer when you enter (when the value in the mouse properties box) have become very annoying.

    Please address and solve the two problems above. Thank you.

    Good news! Now come on. For the moment, you can disable
    KeyScrambler. You can always turn it on when you need it.

  • Remove the dialog box open on several occasions

    When I select any file deletion tab opens several times 20 to 30 times. I feel very difficult to open a file.it is not serious if I select with the mouse or the keyboard. Can someone help me please?

    See if this does nothing,

    http://support.Microsoft.com/mats/windows_file_and_folder_diag/

    Also use it,

    http://support.Microsoft.com/kb/929833

    http://www.SevenForums.com/tutorials/1538-SFC-SCANNOW-Command-System-File-Checker.html

  • We select several files with the file manager

    Slate with Android 4.4 21

    Multiple files can be selected in file manager to have the same approach.

    My workaround for the problem of "not writing files on USB key" was to install dropbox on the slate.

    This allows me to select a file (usually screenshots for instuctions) and copy it to dropbox.  So I delete the files.

    I want to be able to do these operations on multiple files at a time instead of all the necessary selections to make them one by one.

    I discovered that if you do a long press on a single file to implement mode "tool", you can tap on other files to add or remove the selection.

    I try to keep this slate reasonably stock because we use it to support the development of software that is used on the units that are used in manufacturing.  More similar we can keep this for manufacturing units, the fewer problems we should see because of incompatible software.

  • catch the dialog box "open field"?

    Hello world

    I have an EditField with a limited number of characters in the line. If the user types an equal number, or more characters, "full field" default dialog box appears. Is it possible to change the text in this dialog box?

    lol but you might use a field without maxchars and implement a control of the length of yourself.

  • Photoshop crashes with the dialog box open to 8.1 Windows

    I just upgraded Windows 8.0 for Windows 8.1. I have Photoshop CC, I also Photoshop Elements installed. On occasion, CC of Photoshop crashes when you use the open dialog box. It blocks and then explore. The only way to solve it is to restart the PC.

    Has anyone seen this behavior. I have the newspaper now.

    Thank you

    Bill Byrnes

    Yes, it is a dialogue of BONE, but Photoshop does not display icon or image - that is, until the BONE and shell extensions, that you have added.

    Most likely one of your shell extensions (to provide icons) has a bug.

  • I set up the new user on my MacBook Pro with the parental control, and I want to allow access to Word, Excel, PowerPoint for Mac.  I have those checked in the dialog box list, but they may not appear in its applications. Am I missing something?

    I set up a 'user' for my son and use parental controls.  I want to him to have access to Word for Mac, and it appears in the list of applications I can check to allow use for.  However, when we opened a session under his username, these applications do not seem to be anywhere.  When you configure new users, applications such as Word for Mac or the available Pages on users?  I can't find any information to help in this regard.  I don't know if I'm missing something under user put up, or parental controls, or both.  Any help would be greatly appreciated!

    These requests should be made available, provided you installed then in the folder/applications, not in a private folder ~/Applications for a specific user.

  • How can I remove a shortcut from the dialog box 'Open with' in Windows 7?

    Inadvertently, I added a few shortcuts to open with that are unnecessary (I chose .exe that are not supposed to work this way, as a few .exe 7zip), but I'm unable to remove from this menu.

    I found a Microsoft article on this operation, but he says it's for Windows 8, tells me to click on the version for Windows 7, which brings me to a search page, and when I search for it, it shows links that take back me to the original page, so I'm going in circles.

    http://support.Microsoft.com/kb/258860

    How can I do this?

    Hello Dave!

    Have a look here: http://www.sevenforums.com/tutorials/96077-open-clean-up-remove-programs.html

    (When you scroll down on this page, you will find many more related tutorials)

    This link might be interesting, too: http://www.howtogeek.com/howto/18119/remove-programs-from-open-with-menu-in-explorer/

Maybe you are looking for

  • BT toolbar appears

    Since the update of this morning of firefox it does not display my Bt toolbar that it won't show my yahoo toolbar that I lost 3 hours trying to solve this problem please help me I am at my wits end...

  • Are there limits of 'bandwidth' BlueTooth?

    Do not know if I use the right terminology here I have a MBP 15 "of the retina mid-2015.  I am using a keyboard Apple BT, Logitech BT mouse (from the store) and headphones from Plantronics BackBeat Pro BT.  When all are connected, the sound on the he

  • X 230: keys broken / loose

    Hi all. I bought a ThinkPad X 230 summer 2013. It has been working well so far, but a few days ago, I started to notice that the "n" key has been a little loose. I pressed it, it makes a "clicking" sound and returned to its normal position. However t

  • BUG: 1 D table sort isn't sorting table of Classes and table Clusters contain Classes

    the function "sort the table 1 d. I wanted to sort the array of Clusters [number and class]. But to my surprise, LV is not like him. Okay, I need sort table Classes. But maybe once in the future I will. :-) 'Research in table 1 d' is the use of class

  • Print Preview does not work.,... text of page does not print

    printer prints do not the page