Scan a folder on a different computer for new files

Hi all,
I need to scan a folder for new files. I already have a deamon that can do this without a problem. What i need to do, is to scan files on a different computer. The program is going to run on a windows PC and needs to get data from a machine using Unix. I was able to get this done between two windows PC by mapping the drive of the other computer, put i cant do this with Unix.
I found on the net a class used to make an FTP client(edtftpj-1.5.4). This works fine to get the folder contents once, but it dosen't scan it to see if there are new files. I could of course just loop this FTP client, but this could get very slow if there are to many files in the folder.
So do you guys know of a way that i could scan this Unix machine for new files?? anything to give me a hint on where to look would be apreciated.
Thanks in advance
Alex

why should we help you make a program that can be used to spy on people, because that's what you're trying to make (even if it's not your current purpose for it, but then it wasn't the purpose of the person who wrote the Michaelangelo virus to write a virus...)?
It doesn't work on Windows either. As you noted you need to create a drive mapping, which effectively makes the mapped drive available to the other machine as if it were a local drive (applications, including Java applications, don't notice the difference).
You can install a daemon on Unix machines that allows you to expose drives on them for access over networks as well, similar to what you can do with Windows machines.
That's your best bet.
Alternatively you will need to create some sort of server running on the Unix machine which does the work for you and reports the results to your main application on demand through a network connection.

Similar Messages

  • Will iTunes Match scan my computer for audio files?

    Will iTunes Match scan my computer for audio files or do the file need to be in iTunes?

    Hi,
    Track needs to be in your iTunes library.
    Jim

  • Please choose a different name for the file

    How can I stop this message appearning ?

    By choosing a different name for the file?
    You will need to provide a lot more information. 
    What are you trying to do when you see the message?
    What version of Sqldeveloper are you using?
    What operating system are you running on?

  • How do i set a default group (not staff) for new files?

    by default, new files created from within applications appear to be assigned group "staff", regardless of the folder in which they are being created.
    i want new files to inherit the group of the folder in which they are being created. if i create a new file from the terminal command-line, this works. note that it also works when creating new folders from the finder and "save as" dialogue boxes.
    how do i get this to work for new files saved from all applications?
    thanks.

    I usually use the .NET method myself, but if I were forced to poll I would do something like this.  I use a variant to hold the list of filenames.  I would only poll the folder info, when it has been modified then do the Folder List.  Any new files are spotted when the variant attribute does not exist (Replace = FALSE), and this is added to the array.

  • Default optimization for new files in Acrobat 9 Pro

    When I create a new file in Acrobat Pro 9, it automatically saves as version 1.6 (Acrobat 7.x). Much as I would love the whole world to have the latest reader version on their computer, the reality is that many of my website's users have older versions installed. As a consequence, I need to optimize all files as version 1.4, otherwise they won't be able to open the documents in their browsers.
    Why isn't there a preference setting to optimize all new files as 1.4 by default? This would save having to run the optimizer every time. Also, if I start from a file that is already optimized as 1.4, I extract a page and save it, this saves as 1.6. Why? If I am starting from a 1.4 PDF, surely that's the version I want?
    So every time I extract a page, tese are the steps I have to take:
    1) Extract and save the page
    2) Optimize it for 1.4
    3) Save it again (after confirming that yes, I do indeed want to overwrite it).
    I do this several times a day and it's an absolute pain in the neck, which could be avoided by implemeting any of these features:
    1) A setting under Preferences> Default PDF Version for new files;
    2) A PDF version selection box within the "Save As" dialog (I believe this feature has been requested by others);
    3) Acrobat Pro realizing that you have extracted the page from a 1.4 file and therefore saving the new file with the same format;
    4) Some sort of batch optimization option, so I only have to run the conversion once.
    Frankly I'm surprised none of these features already exist.
    Come on Adobe, is this really so hard to do?
    Thank you.

    Acrobat : Advanced menu : Preflight…
    Then:

  • How to add support for new file type.

    Using the ESDK, I would like to add support for new file type ( a new extension). this new extension will function like any other non visual code editor but will have specific syntax highlighting, code folding and explorer.
    I am trying ot figure out if I need to create a new editor or use existing JDeveloper code editor and add support for new file type. Does anyone have a high level outline on how to do this using the ESDK that is specifically targeted at adding new file type support for a text based code editor?
    I have looked at the Samples and keep going in multipe directions. It would be cool if there was an example that was how add syntax higlighting for new file type.
    Thank you

    Brian, thank you. I looked at this extension and it answered a lot of questions for me. I was going in the right direction but needed a little help and bost of confidence, this is just what I needed. I created the LanguageSupport, LanguageModel, Addin, Node and TextDocument that are specific to the new file type. I was getting hung up on how to hook this into the JDevelpoer editor. I keep thinking I have to create a custom editor but it looks like I don't have to and it looks like I can associate this file support with the editor framwork, for version 10.1.3.2, with the following in the Addin Initilize() method.
    Recognizer.mapExtensionToClass(MY_EXTENSION, MyNode.class);
    CodeEditor.registerNodeType(MyNode.class, MY_EXTENSION);
    LanguageModule.registerModuleForFileType(new MyLanguageModule(), MY_EXTENSION);
    I have done this but still not able to recognize the new file type.
    At this point, I just want to be able to recognize the new file and display it's associated icon or display a messare to the message log. I put a System.out.println("test") in the Initilize() method of my addin. then I registered MyAddin in the extension.xml. JDeveloper sees this new extension and it is loaded but I have not been able to show the test message or display the new icon when I open the new file type.
    extension.xml
    <?xml version="1.0" encoding="windows-1252" ?>
    <extension xmlns="http://jcp.org/jsr/198/extension-manifest"
               id="teisaacs.jdev.myext.MyAddin" version="1.0.0" esdk-version="1.0"
               rsbundle-class="teisaacs.jdev.myext.resources.MyResBundle">
        <name rskey="EXTENSION_NAME">My Code Editor</name>
        <owner rskey="EXTENSION_OWNER">Me</owner>
        <dependencies>
            <import version="10.1.3">oracle.jdeveloper</import>
        </dependencies>
        <hooks>
            <jdeveloper-hook>
                <addins>
                    <addin>teisaacs.jdev.myext.MyEditorAddin</addin>
                </addins>
            </jdeveloper-hook>
            <feature-hook>
                <description>My Code Editor</description>
                <optional>true</optional>
            </feature-hook>
            <document-hook>
                <documents>
                    <by-suffix document-class="teisaacs.jdev.myext.model.MySourceDocument">
                        <suffix>my</suffix>
                        <suffix>MY</suffix>
                    </by-suffix>
                </documents>
            </document-hook>
            <editor-hook>
                <editors>
                    <editor editor-class="teisaacs.jdev.myext.editor.MyEditor">
                        <name rskey="EXTENSION_NAME">My Editor</name>
                    </editor>
                    <mappings>
                        <mapping document-class='teisaacs.jdev.myext.model.MySourceDocument">         
                            <open-with editor-class="teisaacs.jdev.myrext.editor.MyEditor"
                                       preferred="true"/>
                            <open-with editor-class="javax.ide.editor.CodeEditor"/>
                        </mapping>
                    </mappings>
                </editors>
            </editor-hook>
        </hooks>
    </extension>
    public class MyAddin implements Addin {
        public static final String MY_EXTENSION = "my";
        public void initialize() {
            System.out.println("MyEditor Constructor");
            new MyLanguageModule();
            Recognizer.mapExtensionToClass(MY_EXTENSION, MyNode.class);
            CodeEditor.registerNodeType(MyNode.class, MY_EXTENSION);
            LanguageModule.registerModuleForFileType(new MyLanguageModule(), MY_EXTENSION);
    }I have added and removed the editor hook along with many other modificaitons to the extension.xml but still not recognizing the new file extension.
    Todd

  • MacOS how to use standard UNIX behavior for new files

    Hi,
    I have one problem. then i create new files and folders on my Mac, they get group owner from parant. How can i say to OS that it should get group owner for new files from user GID? same as it works on UNIX/Linux?
    How it works on Mac:
    MacOS:/ napetrov$ mkdir -p /tmp/new_dir
    MacOS:/ napetrov$ id
    uid=34148(napetrov) gid=45956(users)
    MacOS:/ napetrov$ ls -al /tmp/new_dir
    total 0
    drwxr-xr-x 2 napetrov wheel 68 Aug 13 19:06 .
    drwxrwxrwt 14 root wheel 476 Aug 13 19:06 ..
    How it works on linux:
    -bash-3.2$ mkdir -p /tmp/new_dir
    -bash-3.2$ id
    uid=34148(napetrov) gid=45956(users)
    -bash-3.2$ ls -al /tmp/new_dir
    total 20
    drwxr-xr-x 2 napetrov users 4096 Aug 13 19:01 .
    drwxrwxrwt 22 root root 12288 Aug 13 19:01 ..
    Message was edited by: napetrov

    napetrov, there are two varieties of UNIX behavior regarding the group of a newly created file. The first variety, which Linux uses, comes from System V UNIX — where the file is created with the group ID of the creating user. The second variety, which Mac OS X uses, comes from BSD UNIX — where the file is created with the group ID of the directory in which it is located.
    In some UNIXes that come with the System V behavior by default, the BSD behavior can be applied to a particular directory by setting the directory‘s “setgid” bit. However, it is rare for a UNIX that comes with the BSD behavior by default to provide a way to allow the System V behavior for a particular user. To my knowledge, Mac OS X does not provide a way to allow the System V behavior for a particular user; thus, I’d recommend the explicit use of chgrp to set the group ID of a newly created file to that of the creating user, if that behavior is what your application needs.

  • PSE 12 Has stopped showing thumbnails for new files

    PSE 12 has stopped showing thumbnails for new file imports. Have  Windows 8.1 update

    In the PSE12 Organizer, the last files imported show an hourglass thumbnail. I am importing from the camera card. Other images have the correct thumbnail. I see the spinning icon on the lower bar showing it updating the catalog. Thank you for your assistance

  • Watch Dir For New File

    I'm trying to monitor a directory on my linux server to watch for new files being created. So far I have this.
    watched = new File(inputDirectory);
              long lastModified = watched.lastModified();
              while( true ) {
                  if (watched.lastModified() > lastModified) {
                  Thread.sleep(2000);
              }If a directory has been created within inputDirectory, I want to move into that file and read some of it's contents. How would I get the name of the directory that was created?

    In my project I need to know when only file is created other events are not important for me.Here a code that only trace if file is created on given directory and say what file is created. However I could not totally control every situation but it seems to work .
    public class Main {
    public static File CurrentFile=new File("");
    public static File bestLast=new File("");
    public static int currentNumber=0;
    public static void main(String[] args) throws InterruptedException {  
    File watched = new File("C:\\deneme");
    File[] mycurrentFiless= watched.listFiles();
    currentNumber=mycurrentFiless.length;
         long lastModified = watched.lastModified();
    while(true){
    while( true ) {
              if (watched.lastModified() > lastModified)
    File[] mycurrentFiles= watched.listFiles();
    if(mycurrentFiles.length > currentNumber)
    currentNumber=mycurrentFiles.length;
    for(int i=0;i<mycurrentFiles.length;i++)
    if(mycurrentFiles.lastModified()>bestLast.lastModified())
    bestLast=mycurrentFiles[i];
    if(CurrentFile!=bestLast)
    CurrentFile=bestLast;
    System.out.println("hey, New file is created...: FileName is ..:"+bestLast.getName());
    break;
    }else if(mycurrentFiles.length != currentNumber)
    currentNumber=mycurrentFiles.length;
              Thread.sleep(1000);

  • I used different computer for setup when update to different computer all aplication was deleted

    started my iphone4 to different computer administrator for the setup.then when i tried to use my loptop with new update of itunes all applications on my iphone was gone. pls try to advise me for a solution. tnx

    Syncing to a new iTunes library or computer will erase your iPhone. Only if you back up your phone manually before syncing, you can restore your device from that backup again. A manual backup does not include the sync process.
    Do this to move your phone to another computer:
    Disable autosync in iTunes, connect your phone to your new computer and right click on it in the device list and choose backup. iTunes will backup your phone without syncing.
    Transfer your purchases the same way, choosing "transfer purchases" this time.
    When you connect your phone for the first time, all media content will be erased. But you can restore your settings and app data from your manual backup afterwards.
    Don't forget to set up at least one contact and event on your new computer to be able to merge calendars and contacts when you sync the iPhone for the first time.
    Music is one way only, from the computer to your device, unless you bought the songs in iTunes and transferred your purchases.
    There is 3rd party software out there, but not supported by Apple, see this thread: http://discussions.apple.com/thread.jspa?threadID=2013615&tstart=0
    About backups and what's saved: http://support.apple.com/kb/HT4946
    How to back up and restore:http://support.apple.com/kb/HT1414
    How to download apps for free again:http://support.apple.com/kb/HT2519
    Saving other data is also described here. How to back up your data and set up as a new device
    To get your content back, connect again to the old computer and restore from the latest backup, then try the process described above.

  • How do I change the default save location for new files in Pages back from iCloud to my Documents folder?

    I just upgraded OSX to Mountain Lion and Pages to 4.2, and because OSX is syncing with my iCloud account, when I go to save a new file in Pages it defaults to try to save to my iCloud account rather than giving me the folder structure on my hard-drive that I prefer. It requires two extra steps to save to the proper place in my Documents folder on my hard drive.
    Is there a way to reset the default so that when I go to save a new file, the folder structure opens to the last saved folder (like it does in other non-iCloud applications) rather than defaulting to my iCloud, and to do it without just removing documents from my iCloud account entirely?
    I checked the Preferences for both Pages and iCloud and found nothing about this.

    What I meant is turn off Documents and Data in iCloud in OS X. Keep it on on your iOS devices. iCloud will sync documents between the iOS devices and make them available on the iCloud web site, but it won't mess up iWorks' open and save dialog boxes. It also won't assume that you want all your documents in iCloud, which I think is undesirable anyway.
    Keep iOS and OS X separate, and use the web site to move files between the two as necessary.
    iOS iWork is different from OS X iWork. There are fewer fonts on an iOS device. iOS iWork programs have slightly different feature sets than OS X iWork programs, and the file formats are different. iCloud automatically converts the file format when necessary, but if you make a habit of saving things directly to iCloud, you are limited to the lowest common denominator between the two versions of iWorks. So why would anyone want iWork on the Mac to open and save documents on iCloud by default?
    If you want to store files in the cloud and sync them on your Macs, SugarSync is a much better solution. It lets you choose your sync folders, it doesn't make you reorganize your files, it lets you sync all file types, it doesn't convert files to a different format and back, and it stores everything in the cloud, too. Just the simle act of saving a file backs it up and syncs it. I wouldn't live without it. iCloud is best with iTunes purchases and synchronizing Mac settings and iOS files; I woudln't live without it. The two make an unbeatable combination.

  • Copying two layers through same selection mask produces different dimensions on new file

    Hi all,
    This is driving me insane!
    I'm creating an animation in AE eventually but initially have two hand drawn images of the same object that I've scanned into PS.
    I have a single mask created that I turn into a selection to copy the two images to output as new single files to then import as 2 frame png sequence into AE.
    Normally, and this is critical, the dimension of the new files would/should be exactly the same.
    But they're not!
    How is this possible, the selection is the same for both layers.
    Any suggestions, help, assistance, very much appreciated.
    thanks
    Yan

    yancowles wrote:
    Still annoying though, I'm creating the double drawn animation effect and it would help if I could make the new files to exactly the same dimensions quickly and easily somehow.
    Menu file>Save As to create a new file Photoshop is not a file editor. For a new document the same size menu File>New or Ctrl+N then use the preset pull down menu  and select the open document that has the size you want.
    You can also script a new document from selection.
    /* ==========================================================
    // 2009  John J. McAssey (JJMack)
    // ======================================================= */
    // This script is supplied as is. It is provided as freeware.
    // The author accepts no liability for any problems arising from its use.
    // Download from the web and fixed to work better
    <javascriptresource>
    <about>$$$/JavaScripts/NewDocumentFromSelection/About=JJMack's New Document From Selection.^r^rCopyright 2009 Mouseprints.^r^rJJMack's Script.^rNOTE:New Document From Selection!</about>
    <category>JJMack's Script</category>
    </javascriptresource>
    // enable double-clicking from Mac Finder or Windows Explorer
    #target photoshop // this command only works in Photoshop CS2 and higher
    // bring application forward for double-click events
    app.bringToFront();
    // ensure at least one document open
    if (!documents.length) alert('There are no documents open.', 'No Document');
    else main(); // at least one document exists proceed
    //                            main function                                  //
    function main() {
              try {
                        // Set the ruler units to PIXELS
                        var orig_ruler_units = app.preferences.rulerUnits;
                        app.preferences.rulerUnits = Units.PIXELS;
                    if(hasSelection()) newDocFromSelection();
                        // Reset units to original settings
                        app.preferences.rulerUnits = orig_ruler_units;
              // display error message if something goes wrong
              catch(e) { alert(e + ': on line ' + e.line, 'Script Error', true); }
    //                           main function end                               //
    function hasSelection(doc) {
              if (doc == undefined) doc = activeDocument;
              var res = false;
              var activeLayer = activeDocument.activeLayer;          // remember active layer
              var as = doc.activeHistoryState;                    // get current history state #
              doc.selection.deselect();
              if (as != doc.activeHistoryState) {                    // did the deselect get recorded
                        res = true;
                        doc.activeHistoryState = as;                    // backup and reselect
              activeDocument.activeLayer = activeLayer;          // insure active layer didn't change
              return res;                                                   // return true or false
    function newDocFromSelection() {
              var AD = app.activeDocument.name;      // remember current document name
            /* the following code seems to be from the script listener  what it
                does is to add a layer via copy selection ( Ctrl+J) which will fail
                if the select area of the active layer is empty then code then creates
              a new documents with a normal layer cotaining the contents of that layer */
              executeAction( charIDToTypeID('CpTL'), undefined, DialogModes.NO );//
                        var desc5 = new ActionDescriptor();
                                  var ref2 = new ActionReference();
                                  ref2.putClass( charIDToTypeID('Dcmn') );
                        desc5.putReference( charIDToTypeID('null'), ref2 );
                        desc5.putString( charIDToTypeID('Nm  '), "NewDoc"+documents.length.toString());
                                  var ref3 = new ActionReference();
                                  ref3.putEnumerated( charIDToTypeID('Lyr '), charIDToTypeID('Ordn'), charIDToTypeID('Trgt') );
                        desc5.putReference( charIDToTypeID('Usng'), ref3 );
                        desc5.putString( charIDToTypeID('LyrN'), "From Selection" );
                        executeAction( charIDToTypeID('Mk  '), desc5, DialogModes.NO );
                        app.activeDocument.trim(TrimType.TRANSPARENT);          // trim new document transparency
                        activeDocument = documents.getByName(AD);          // retun to the old document
                        activeDocument.activeLayer.remove();                    // delete layer added via Ctrl+J 

  • Read-only access permissions for new files/folders?

    System:
    Clean Install on new intel Xserve
    10.4.8 Server w/ Open Directory
    Windows clients can read/write completely fine...
    Clients connecting using AFP (whether Standard or Kerberos authentication) can access files, but when new files/folders are created on the server, they register as full permissions for the user who created them, but not for the rest of the group.
    The share(s) in question are set using POSIX from WGM: Full access for owner/group/everyone (changed it to this thinking it would help, but it does not). Of course, no one can make changes to a newly-created/deposited files/folders, which is just plain silly.
    I can chmod the permissions recursively from a script (which fixes the problem, of course) on a regular basis so that its not (as much of) an issue, but there is still a 5-minute lag for the script to kick in, since we don't want to bombard the server with chmod requests every minute....which is unnecessary in the first place!
    I have plenty of other setups which are identical but have no such issue...
    Any reason why POSIX permissions on the share are being ignored from every user account?
    Thanks,
    k

    "That's default posix behaviour no matter what access permissions you set on the sharepoint."
    I'm afraid this is dead wrong. What matters most is how you set permissions on the share, not if you've chosen to inherit vs. using POSIX. POSIX is still used in inherit functions, though you can use ACL's to override them. In this case, ACL's are not being used on those shares (though we tried it).
    After all, why would Apple (let alone anyone else) even offer the ability to change POSIX permissions on a share if it didn't have any effect? That would be somewhat contradictory in nature.
    Like I said before, I have several other installations which are identically setup that have no such issues.
    As for Windows, it is also not set to inherit permissions; we're setting those explicitly. And they work fine.
    Any other ideas?
    Thanks,
    k

  • How to set default sharing permission for new files???

    Hello. I have an imac 24" and a macbook pro 15". they are connected over an airport network. i have file sharing set up, which is working great. i am having one problem though.
    whenever a file is created on either computer, it defaults to only allow the other computer to access it read only. is there a way to set a preference that will make all new files that are created to have read & write permission by the other computer????

    the easiest way to do that is to connect from one computer to the other not as a guest but as a registered user. then any files you create will be owned by that user. so if you have user1 on imac and user2 on mbp connect from the imac to the mbp as user2.

  • How do i get itunes to scan my computer for mp3 files

    Hello,
    I just got a new computer and I have all my old mp3 files on my disc.  How do I get itunes to scan my drive and import all my 10,000 songs at one time?

    When you first install iTunes, it offers to do a one-time scan of your hard drive.
    If you miss that opportunity, you can add music at any time using the command File > Add Folder to Library.  That command brings up a dialog where you can navigate to the folder you want to add, e.g. My Music.

Maybe you are looking for