Event handler if new File added in current folder

Hi folks,
I'm just trying to write a little jsx script for Bridge CS6.
How can I implement an event handler that will react if the user adds a new thumbnail (new file) to the current folder in bridge.
I've tested it with this code, but it doesn't work:
app.document.thumbnail.watch ("children", function(id, oldVal, newVal) {
     $.writeln (oldVal + " to " + newVal);
     // some code here
Thanks. Greetings

Beautiful. Works as advertised. Thank you for pointing it out to me. Unfortunate that a basic subset of this extension's behaviour doesn't ship with Thunderbird out of the box, though.

Similar Messages

  • Permissions in a folder are not applied to new files added by users over shared network

    New files added to a shared folder do not inherit the permissions of the folder but rather retain the permissions of the user. Because the purpose of the folder on the network is to allow multiple users access to all the files (read and write), these new files cannot be accessed and editd by others.Is there a way to have the new files automatically inherit the folder permissons? I am aware of the "Apply to enclosed items " drop-down in the Get Info window but this is not practical given the number of new files that are produced and filed.
    THanks,
    JD

    If it's the folder is on the boot drive then the only way to accomplish this is with a combination of groups and ACL's as far as I know. There may be other ways but this is the one I know.
    You say the folder is on the network but is on the boot disk, how are you setting this up and are the users accessing this all from Mac's? And they all have accounts on this Mac?
    In a nutshell you would setup a group that all the users needing to access the folder belong to and then setup the ACL on the fodder so that all member's of that group will have full permission to whatever is in the folder.
    So first in Users&Groups create a group for this and add all the users who need access.
    The do to the folder and change its group to the group you created and change its mode to 775 (or 770 if you don't want anyone else having even read access on the folder)
    Then enter this
    sudo chmod -R +a "GroupNameCreated  allow delete,chown,list,search,add_file,\
    add_subdirectory,delete_child,file_inherit,directory_inherit"  folderToChange
    Now the weird thing is if you look at files in the folder they will appear to have the normal Unix mode of 644 but anyone in the group will have read, write and delete permission on the items in the folder.
    I suggest you play with this on a test folder and seeing if it meets your needs before changing the working folder.
    Also this will not change anything already in the folder it only applies to newly created files/folders
    regards

  • How can I make itunes detect new music added to Music folder

    How can I setup itunes to automatically detect new music added to my music folder? Under the advanced setting I currently have Itunes set to view my music folder where all my music is located. Im using Windows 7, Itunes Version 10.4.1.10. Currently I have to add new music manually and that's *****. I have over 2000 cd's that I need to rip. Please help. Thanks

    If you are ripping CDs, you can rip with iTunes and the tracks will be added to your iTunes library without manual intervention.
    But if you already have the files, or are using something other than iTunes to rip, you will note that iTunes does not automatically detect when new files have been placed in a folder.  You can add this capability by using a 3rd party program such as iTunes Folder Watch.

  • Telling ID CS5 to seek a linked file in the current folder

    For at least 5 years (and all the versions of ID), I've been unable to set up a link on text or a graphic that, when clicked, will open another PDF, because I want Acrobat Reader to look for the new PDF file in the same folder/directory as the current PDF.
    For all those years, my workaround has been to create the PDF and then in Acrobat use the Link tool (Tools > Advanced Editing > Link Tool) to select a rectangle over the text or graphic and set up a link to the file in the current directory. When I do the link this way, then save the PDF, then move the PDF to a different computer, Acrobat Reader can find the file in the current directory, even though the explicit path in the link is to a directory that does not exist on this second computer.
    So, today, I thought I'd see whether ID CS5 now sets up what I want. I selected some text, selected New Hyperlink from the Hyperlinks menu, told it I wanted to open a file. I have tried two seperate ways to describe the file, neither of which allows Acrobat Reader to correctly find the file:
    I browsed to the file (mnd.pdf) in the current directory where both the x.indd file is and the x.pdf file will be. When I take the finished x.pdf file to a new computer and click on the link, Reader puts up an error it cannot find the file, and it names the explicit path from the first computer (which intentionally does not exist on the second computer).
    I typed in ".\mnd.pdf" as the standard notation meaning to look in the current directory. In this case, Reader on the second computer does not put up an error, but no file opens. Basically, nothing happens when I click on the link (except for the warning asking me wheher I want to allow this operation).
    Bottom line questions: How can I set up a link in ID CS5 that will always look for a file named "MND.pdf" and always in the same directory as the currently open PDF? I know I can make it happen in Acrobat 9, but it's inefficient to have to set up the link every time I re-create a PDF instead of once in the InDesign file.
    Thanks,
    John

    Hi, Jongware,
    It is a bug since CS4, agravated in CS5, because until CS3 it worked very well.
    In fact, it worked through out a lot of pages. I think this was not created only to pages side-by-side but in fact to those articles that continued several pages ahead. So, in a magazine, when one has to break an article and continue this article in other page, one could (and still can) put a text frame in the of the first part of the article and type "Continue on [next page marker]". Then link this text frame with a new text frame on the page where the article continues, (on top of 2nd part of the article) and type "Continued from [previous page marker]".
    This situation – where text frames are in the document pages – still works fine.
    The problem is when this is a constant and you want to put it in master pages, and now it simply does't work. I mean, when every odd or even pages have both numbers. For me, it's a major problem, because several of my clients just love this!
    Is anyone of Adobe reading this? Are you going to help us and fix this problem, please?...

  • Every time I save a project it creates a new file in my movie folder

    Instead of updating the previous file a new one is created so I have numerous files of the same project and can't figure out which one to open. Things are getting more and more confusing the more I use my G4 since installing iLIFE '06. Can anyone help me try to get a handle on this?

    Chris, my guess is you may be confused by one or more tilde files inside the project, a project file with a tilde (~) in its name.
    If the project was begun in iMovie 4, the project resides in an iMovie 4 type-folder, not an iMovie 6 package. The folder lets you see the tilde file. For projects begun in iMovie 5 or 6, the project is a package instead of a folder. And you never see the tilde file, for the package looks like a file instead of a folder.
    The problem is discussed here:
    http://discussions.apple.com/thread.jspa?messageID=1971832&#1971832
    My guess is you're opening the wrong project file to re-open the project. So when you save, it's saving a new tilde file.
    The whole issue is rather confusing. Check out the topic, and if you can't get it straightened out say more about what's going on there.
    Karl
    PS: If you haven't yet, create a new iMovie 6 project, add something to it and save. To look inside the package, Control-click on the project (in the Finder) and choose "Show Package Contents" from the popUp menu. You will see one tilde project file and one project file without a tilde. That's ALL the project files you should ever see.

  • Finder - Create new files directly from a folder using finder ?

    In Finder, is there a way to do a right-click in a folder and create a new file like: New Text File or New Document from that location?
    I used to do this oftenly in Windows (right click, New Word document) but I have not found it in Mac OS X, any work around ?
    Thanks

    Try the [Apple feedback page|http://www.apple.com/feedback>. However, note that this is unlikely to be added. It would be a very cumbersome feature.
    On Windows, you're almost guaranteed to be tied to a particular set of document creation tools. If you're using an office suite other than MS Office, you're so weird you might as well be using a Mac! This means that commands like "New Document" make sense there.
    On a Mac, a "document" could be created with MS Word, Pages, TextEdit, NeoOffice, OpenOffice, Mellel, Nisus Writer Marinter Write, or any of a host of other programs. (Mac users tend to put less emphasis on the popular tool and prefer to use the tool that "fits the hand" best.) Further complicating things is the fact that "document" is a very generic term, since every spreadsheet is a document, every Photoshop file is a document, etc. The contextual menu would rapidly become unmanageable if it had to fill up with "New Whatever Document" commands for every app on your hard drive!
    It is possible for you to add your own custom services to the contextual menu using AppleScript or Automator, and you should be able to create services to create new documents for the apps you use frequently. Check on the [AppleScript forum|http://discussions.apple.com/forum.jspa?forumID=724] for guidance on how to do this.

  • Why can't DW CS5 see jpgs, new files in website root folder in Bridge CS3?

    Help!  Upgraded to DW CS5.  Web site done in DW CS3, used PS3 and Bridge CS3 for photo prep etc. Root folder is  in Bridge CS3.  I tried to use "Place"  to DW CS5- but Bridge opens DW CS3 instead, even with page open in DW CS5. (Have deactivated DW CS3 in associations.)   New pages,files and additions are "invisible" to DW CS5.  Why?
    Before the upgrade,files in the root folder in Bridge were listed and  immediately available to DW on Local and Remote.   (Mac OS X10.5.8-2.2GHzIntel/mem 2GB 667 MHz)
    I'm new at this stuff and have combed the Help-Knowledge Bases-DW and Bridge and haven't found anything remotely helpful or even similar? .Must be something obvious everyone knows  to do.

    Problem went away this morning!
    I tried this step again (a third time) after starting up my computer:
    Still trying to get my composite in "B" recognized by LR, I first deleted the composite from "B" using explorer, then went into LR and moved the file from "A" (where LR recognized it), into "B". 
    This time it worked, the file moved successfully and appears normally in LR.
    Don't know if the re-boot helped, or I was making some silly mistake that a good night's sleep cured.  If the later, I apologize to all who scratched their heads over this one. 
    Thanks,
    Jerry

  • How do you get a new file in a shared folder to inherit permissions

    I have a shared folder that I share with a co-worker and having trouble with the permissions for new files/folders.
    When he creates a new file or new folder, the permissions for that file/folder are set as read only for myself. The parent shared folder is set at "Read/Write" for both of us.
    Is it possible to control the permissions for new files/folders?

    Actually, that property used to go in the entry for that sharepoint in the "NetInfo" database, and really only worked properly when 'afpuse_parentowner' was also set. The .plist file controls the behaviour of the afp server as a whole, not that of individual share points.
    I'm not sure what the "DirectoryService" equivalent is - a lot of the things have similar names but differ in "case", but some things are completely different or absent.
    Unfortunately, I'm not equipped to test these things myself but changes can be made using 'dscl', or possibly by editing the flat files directly in a manner similar to what is described here:
    http://www.macgeekery.com/hacks/software/netinfo_dead

  • I cannot create new file (.xslx) inside a folder with right click.

    I work with excel 2007 in window 7. Usually I create new files (.xlsx) by right click while I am inside a folder. But recently I have lost this opportunity. Now whenever I open a folder and want to create a new file (either .xlsx or .doc) I right click
    there. But there I find neither excel file icon nor word file icon. Power point, Access, Publisher file icons can be found there at that time. I do not know how I have lost the opportunity. Being failed to create files inside a folder now I go to start button
    or office button to create a new file.
    But I want to have the previous opportunity so that I can create a new file (excel or word) while I am visiting inside a folder. Is it possible? Thank, Nurul Amin.

    Hi,
    I would agree with Repair step provided by Robert, this will rewrite all the registry keys into the computer. Please have a try and let us know the result.
    Also, another quick way to rewrite all the registry keys and reregister the product is to run the problematic Office applications with "/regserver" switch:
    Press Win + R and type "winword.exe /regserver" or "Excel.exe /regserver" in the blank box, then press
    Enter.
    You might also want to give this a try.
    Regards,
    Ethan Hua
    TechNet Community Support
    It's recommended to download and install
    Configuration Analyzer Tool (OffCAT), which is developed by Microsoft Support teams. Once the tool is installed, you can run it at any time to scan for hundreds of known issues in Office
    programs.

  • Using Automator to Copy Only New Files to a Destination Folder

    Hello,
    I need an AppleScript to copy a source directory (including all subfolders and files) to a destination folder, but one that checks for duplicate files and only copies files across from the source directory if they aren't already contained in the destination directory.
    I have a script that checks the files, but it only copies files from the source directory and ignores all subfolders and the files within those.
    Can anyone help?
    Thanks
    Reynell79

    red_menace wrote:
    You can create a Service workflow to get the folder(s).  The workflow would consist of actions to save the input items to a vatiable (so they can be refiltered), then get the input items, apply a filter, and move the resulting items - for example:
    Service receives selected folders in Finder
    Get Folder Contents
    Set Value of Variable { Variable: Original Items }
    Filter Finder Items { Find files where: kind is music }
    Move Finder Items { To: Automatically Add to iTunes }
    Get Value of Variable { Variable: Original Items } ( Ignore Input )
    Filter Finder Items { Find files where: kind is image }
    Move Finder Items { To: Album Artwork }
    ...repeat the Get/Filter/Move actions as needed for other filters
    Thanks, the "Set Value of Variable" concept is what I was missing. It almost works. The music files get moved, but then it says the workflow encounters a problem and the image files aren't being moved. I'm assuming it's an issue with steps 5-7. Thoughts?

  • Event handling without new class

    I'm new to Java, so please bear with me.
    I'm working with a file management software called Intralink which allows automating tasks by recording keystrokes or writing instructions in Java. A typical recorded script would look like:
    // Start Macro Recording
    import com.ptc.intralink.client.script.*;*
    *import com.ptc.intralink.script.*;
    public class newpn2 extends ILIntralinkScript {
    ILIntralinkScriptInterface IL = (ILIntralinkScriptInterface)getScriptInterface();
    private void run0 () throws Exception {
    IL.deselectAll( "WSPI" ); // recorded step: 1
    IL.select( "WSPI", "New_Generic/template_sm.prt" ); // recorded step: 2
    } // End of run0
    public void run () throws Exception {
    run0 (); // recorded
    } // End of function
    } // End Macro RecordingI don't know why but the run0() function has to be called from the run() function. (to clarify that, the run0() can be called from anywhere but all the statements beginning with "IL." are ignored unless it was called from the run() function) I'm trying to write something that uses a dialog box created with JFrame, contains a few combo boxes, and has a JButton to then start the run0() function. This fails because the run0() ends up being called from the actionPerformed class, similar to below.
    public void actionPerformed(ActionEvent e)
    try
    run0();
    catch (Exception ex)
    System.out.println("Error..." + ex);
    }I've tried doing it with an anonymous inner class but the result is the same. Is there any way to detect a button click and act on it within the same function that creates the button?

    Vmtr wrote:
    I understand what you're suggesting but this would still require me to call the run0() function from within the listener class and (for whatever reason) the "IL." commands are ignored if they are not in a run0() function called directly from a run() function. I'm assuming that this is a quirk built in by the makers of Intralink and I am just trying to find a way around it.Something is happening behind the scenes, something that I don't see evidenced by your current code. Since Intralink is not your class, I guess it is impossible to create a true SSCCE. When I created an SSCCE based on your code, there were no problems:
    //import com.ptc.intralink.client.script.*;
    //import com.ptc.intralink.script.*;
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    //import javax.swing.border.*;
    //import java.util.*;
    //import java.text.*;
    //import java.io.*;
    //import java.sql.*;
    //import com.ptc.intralink.ila.*;
    public class forum extends ILIntralinkScript
      ILIntralinkScriptInterface IL = (ILIntralinkScriptInterface) getScriptInterface();
      private void run0() throws Exception
        JOptionPane.showMessageDialog(null, "In the run0 function!");
        IL.openWindow("Workspace", null, null); // recorded step: 1
        IL.selectTree("FTLOCALDB", "Local Database"); // recorded step: 2
      } // End of run0
      public void run() //throws Exception
        JButton button1 = new JButton("Done");
        button1.setPreferredSize(new java.awt.Dimension(310, 18));
        JFrame f = new JFrame("New Part Number");
        // add this so it exits nice:
        f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        f.setSize(360, 300);
        f.setResizable(false);
        Container content = f.getContentPane();
        content.add(button1);
        button1.addActionListener(new ActionListener()
          public void actionPerformed(ActionEvent ee)
            try
              run0();
            catch (Exception ex)
              System.out.println("Error..." + ex);
              ex.printStackTrace();
        f.setVisible(true);
      // get this all to run
      public static void main(String[] args)
        SwingUtilities.invokeLater(new forum());
    // dummy classes to allow for compilation
    abstract class ILIntralinkScript implements Runnable
      public ILIntralinkScriptInterface getScriptInterface()
        return new ILIntralinkScriptInterface();
    class ILIntralinkScriptInterface
      public void openWindow(String string, Object object, Object object2)
        JOptionPane.showMessageDialog(null, "in method openWindow(" + string + ", " + object + ", "
            + object2 + ")");
      public void selectTree(String string, String string2)
        JOptionPane.showMessageDialog(null, "in method selectTree(" + string + " ," + string2 + ")");
    }

  • Transfering new files added to the iPod into the iTuns library

    Hi,
    I have resently added albums and video to my iPod from a friends iTunes libary, I returned home to find that even though it was my iPod I could still not transfer the files within it.
    I was wondering if anyone knows a way round this? Even though it is supposed to enforce copyright!
    Thanks for reading,
    x Sarah x
    MA002FB   Windows XP Pro  

    Unfortunately, this is illegal and cannot be discussed here
    btabz

  • Fire up a copy thread when the new file added to the directory

    Hello,
    I am writing a thread to copy the files from a specific directory to the server. Since the files are sent to this directory by another group and I want to do the coping whenever the files are in the directory.
    Could you tell me how I can monitor the files in the directory and fire up the copy thread when the files are there?
    Thanks in advance!
    David

    Guess you can use a thread to check the directory for any changes and, if found, do the copying. You can use the same thread you used to copy for checking as well.

  • New files in iTunes music folder

    Hello...I made a change from a Windows computer to the iMac. I copied all my music files from my Windows computer to my external hard drive, and then copied from the external hard drive to my iTunes music folder. When I compared the info between my iTunes music folder, and the music files on my external hard drive, the iTunes music folder had more files. By looking through the files it looks like two extra files were added to each album folder....a folder.jpg file and a AlbumArtSmall.jpg file was created. I didn't have those files coming from my windows folder, how come they show up now? Are those two files necessary?

    I have a few of these also - all from downloaded albums, which would either have been .zip or .rar files when they arrived on my desktop. This ring any mental bells with you? (I never questioned what they are, and I only imported the music files to iTunes).

  • PDQ - run batch file on user current folder...

    Hi,
    I'm running batch file:
    cd %USERPROFILE%\AppData\Local\Microsoft\Windows\Temporary Internet Files\
    but it's not opening the current logged on user
    how to deploy it on current logged on user?
    thanks,,,
    This topic first appeared in the Spiceworks Community

    This is not working for me in Windows 8.  I have a shortcut to an EXE file located in"C:\Users\admin\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup".  If I set the shortcut to run as administrator (screenshot attached) then it does
    not run at all on startup.  If I uncheckmark "Run as Administrator" then it starts fine (but does not have enough privileges to do what it needs to do).  In Windows 7 this was not an issue since the current user was a local administrator and did
    not need to elevate its privileges further.
    Any ideas how I can work around this problem?  Thanks!
    Ugh... it won't let me attach a screenshot until my "account is verified", whatever that means.

Maybe you are looking for