List files chronologically

Hi,
Can we list the files in a directory based on thier timestamps. i want it to be in chronological order,like the file that was created first shud be first in the list.
can we do this?

Get the fileds in the directory using:
File.list(). Then sort the array using
Arrays.sort() with a custom comparator. The only time information about a file one can get is by using File.lastModified() Regards,

Similar Messages

  • I have imported all photos and videos from my iPhone 5S into Aperture ver.3.4.5 and now cannot find them. I thought I could open a panel showing all imports and merely list them chronologically, but I don't see how to do this.

    I have imported all photos and videos from my iPhone 5S into Aperture ver.3.4.5 and now cannot find them. I thought I could open a panel showing all imports and merely list them chronologically, but I don't see how to do this.  There are over 1800 photos and about 100 videos, any help to locate where they've gone would be appreciated.

    Try to search with a Smart Album for photos and videos taken with an iPhone:
         File > New > Smart Album:
    Add an EXIF rule fro the "Add Rule" drop down menu: EXIF
    and set it to "Camera Model includes iPhone".
    Set the scope of the search to "Library"
    If there are any iPhone images or videos in your library at all, this search should find them.  Then ctrl-click any of the items and select "Show in Project" from the contextual menu.
    Generally, Aperture should be showing your last import in the "Last Import" smart album in the "recent" section". And the "projects" view can be sorted by date, so you should see your recent imports.
    You may want to check all search fields, if searches are active.

  • How to list files that are NOT in a .jar file?

    Is it possible to list files (resources, .gif/.jpg files, etc.) that are NOT included in the jar but are still to be considered part of the application somewhere in the jnlp-file?
    My applications requires lots of icons which I have put into .gif files. So far I kept them in individual files next to the .jar file and that worked fine.
    JWS now seems to support only stuff that is included in (a) .jar-file(s). That in itself woul not be much of a problem, however, when I include my .gif files into the .jar files they seem to get corrupted by the jar-signing process (at least that what's the code says, which can suddenly not handle these images any more).

    My previous seem to have been non-sense. The .gif file were not corrupted, but rather they were not found at all. They actually must NOT be included in the .jar file, or else they are not found. Strange enough, the .properties-file seemingly HAS to be in the .jar file to be found.
    This is something I'll probably never fully understand with java: which file-types it searches where...

  • AppleScript 10.9.0 System Events -10006  Update property list file item

    Have AppleScript that runs without error on Mountain Lion 10.8.5, but errors out on Mavericks  10.9.0.
    At end of script, property list items need to be updated and this is when error occurs.
    Put together a subset of the script, see below) that get the error
    Statement reads "set value of property list item "ArrayList001" to ArrayList001"
    Text of error:
         error "System Events got an error: 'xxx.plist' is not a property list file."
         number -10006 from contents of property list file "xxx05.plist"
    =============================================================================
    property myPListFile : "cbmck05.plist"
    property myPListFilePath : ""
    property constPreviousRunDay : "PreviousRunDay"
    on run
       set today to "Date01" as string
              set List001 to {}
              set List002 to {}
              set myPListFilePath to ""
              repeat with i from 1 to 8
                        set end of List001 to (i * 2) as string
              end repeat
              set myPListFilePath to path to desktop folder from user domain as string
              set fileMyPList to (myPListFilePath & myPListFile) as string
    clear_file(fileMyPList)
    -- First time! need to initalize
              tell application "System Events"
      -- create an empty property list dictionary item
                        set the parent_dictionary to make new property list item with properties {kind:record}
      -- create new property list file using the empty dictionary list item as contents
                        set new_plistfile to ¬
      make new property list file with properties {contents:parent_dictionary, name:fileMyPList}
      make new property list item at end of property list items of contents of new_plistfile ¬
      with properties {kind:string, name:constPreviousRunDay, value:today}
      make new property list item at end of property list items of contents of new_plistfile ¬
                                  with properties {kind:list, name:"ArrayList001"}
      make new property list item at end of property list items of contents of new_plistfile ¬
                                  with properties {kind:list, name:"ArrayList002"}
              end tell
              set previousRunDate to today
              set xxList to (repopulate_lists())
              set ArrayList001 to List001
              set ArrayList002 to List002
    -- save info in the plist file
              tell application "System Events"
                        tell property list file fileMyPList
                                  tell contents
                                            set value of property list item constPreviousRunDay to previousRunDate
                                            set value of property list item "ArrayList001" to ArrayList001     --   <<< ------- error caused by the statement
                                            set value of property list item "ArrayList002" to ArrayList002
                                  end tell
                        end tell
              end tell
    end run
    -- ==========================================
    on repopulate_lists()
              set newList to {}
              set List002 to {}
              repeat with i from 1 to 8
                        set end of newList to i as string
              end repeat
              set List001 to newList
              return List001
    end repopulate_lists
    -- ==========================================
    -- Does the file exist?
    on fileExists(f)
              try
      f as string as alias
                        return true
              on error errMsg number errNum
                        return false
              end try
    end fileExists
    -- Delete the  files if exist
    on clear_file(aFile)
              if fileExists(aFile) then
                        tell application "Finder"
                                  set resultObject to delete aFile
                        end tell
              end if
    end clear_file

    Here's an AppleScript handler that partially works around this bug (warning: it turns each list item into a string).
    on plistWrite(plistPath, plistItemName, plistItemValue)
      -- version 1.1, Daniel A. Shockley
      -- 1.1 - rough work-around for Mavericks bug where using a list for property list item value wipes out data
              if class of plistItemValue is class of {"a", "b"} and AppleScript version of (system info) as number ≥ 2.3 then
      -- Convert each list item into a string and escape it for the shell command:
      -- This will fail for any data types that AppleScript cannot coerce directly into a string.
                        set plistItemValue_forShell to ""
                        repeat with oneItem in plistItemValue
                                  set plistItemValue_forShell to plistItemValue_forShell & space & quoted form of (oneItem as string)
                        end repeat
                        set shellCommand to "defaults write " & quoted form of POSIX path of plistPath & space & plistItemName & space & "-array" & space & plistItemValue_forShell
      do shell script shellCommand
                        return true
              else -- handle normally, since we aren't dealing with Mavericks list bug:
                        tell application "System Events"
      -- create an empty property list dictionary item
                                  set the parent_dictionary to make new property list item with properties {kind:record}
                                  try
                                            set plistFile to property list file plistPath
                                  on error errMsg number errNum
                                            if errNum is -1728 then
                                                      set plistFile to make new property list file with properties {contents:parent_dictionary, name:plistPath}
                                            else
                                                      error errMsg number errNum
                                            end if
                                  end try
                                  tell plistFile
                                            try
                                                      tell property list item plistItemName
                                                                set value to plistItemValue
                                                      end tell
                                            on error errMsg number errNum
                                                      if errNum is -10006 then
      make new property list item at ¬
                                                                          end of property list items of contents of plistFile ¬
      with properties ¬
                                                                          {kind:class of plistItemValue, name:plistItemName, value:plistItemValue}
                                                      else
                                                                error errMsg number errNum
                                                      end if
                                            end try
                                  end tell
                                  return true
                        end tell
              end if
    end plistWrite

  • Issue with List Files option in FTP Adapter-

    Hi All,
    I am getting the following error when I am using the list files option inside FTP adapter. The soa Version I am using is 11.1.1.5
    Exception occured when binding was invoked. Exception occured during invocation of JCA binding: "JCA Binding execute of Reference operation 'FileListing' failed due to: Error in listing files in the remote directory. Error in listing files in the remote directory. Unable to list file in remote directory. Please make sure that the ftp server settings are correct. ". The invoked JCA adapter raised a resource exception. Please examine the above error message carefully to determine a resolution.
    I have configured FTP adapter successfully by giving the following details,
    useSftp –
    username –
    password -
    host -
    port –
    authenticationType –
    preferredCipherSuite -
    and it is working perfectly for getfiles option and it is reading files successfully, but it is throwing error when I am using list files option. I tried this option for listing the files that are in remote directory. Any Help would be appreciated.
    Complete fault
    <messages>
    <input>
    <Invoke1_FileListing_InputVariable>
    <part name="Empty">
    <empty/>
    </part>
    </Invoke1_FileListing_InputVariable>
    </input>
    <fault>
    <bpelFault>
    <faultType>0</faultType>
    <bindingFault>
    <part name="summary">
    <summary>Exception occured when binding was invoked. Exception occured during invocation of JCA binding: "JCA Binding execute of Reference operation 'FileListing' failed due to: Error in listing files in the remote directory. Error in listing files in the remote directory. Unable to list file in remote directory. Please make sure that the ftp server settings are correct. ". The invoked JCA adapter raised a resource exception. Please examine the above error message carefully to determine a resolution. </summary>
    </part>
    <part name="detail">
    <detail>No such file</detail>
    </part>
    <part name="code">
    <code>null</code>
    </part>
    </bindingFault>
    </bpelFault>
    </fault>
    <faultType>
    <message>0</message>
    </faultType>
    </messages>
    May 9, 2013 4:32:00
    Edited by: BK574 on May 9, 2013 2:47 PM

    Is this a bug in SOA suite?
    Following are the properties inside JCA file
    <adapter-config name="List" adapter="FTP Adapter" wsdlLocation="List.wsdl" xmlns="http://platform.integration.oracle/blocks/adapter/fw/metadata">
    <connection-factory location="eis/ftp/FTPService" UIincludeWildcard="*.*"/>
    <endpoint-interaction portType="FileListing_ptt" operation="FileListing">
    <interaction-spec className="oracle.tip.adapter.ftp.outbound.FTPListInteractionSpec">
    <property name="PhysicalDirectory" value="*.*"/>
    <property name="Recursive" value="true"/>
    <property name="IncludeFiles" value="*.*"/>
    </interaction-spec>
    </endpoint-interaction>
    </adapter-config>
    Edited by: BK574 on May 10, 2013 6:30 AM
    Edited by: BK574 on May 10, 2013 6:31 AM

  • How to list files from .jar file in applet?

    I have created applet and export all files to .jar file.
    I use File.list() method in applet to list files from one directory and that works ok but if I try to do that from web browser it sends exception AccessDenied meaning that File.list() isn't allowed in browser.
    I know what's the problem but I don't know how to solve it.
    What I want is to read from directory list of files.
    Help anyone?

    I will post here my code so that can be seen what I want to do:
    import java.awt.BorderLayout;
    import java.io.BufferedReader;
    import java.io.File;
    import java.io.IOException;
    import java.io.InputStreamReader;
    import java.net.URLClassLoader;
    import java.nio.charset.Charset;
    import javax.swing.JApplet;
    import javax.swing.JPanel;
    import javax.swing.JTextPane;
    public class test extends JApplet {
         private static final long serialVersionUID = 1L;
         private JPanel jContentPane = null;
         private JTextPane jTextPane = null;
          * This is the xxx default constructor
         public test() {
              super();
          * This method initializes this
          * @return void
         public void init() {
              this.setSize(449, 317);
              this.setContentPane(getJContentPane());
          * This method initializes jContentPane
          * @return javax.swing.JPanel
         private JPanel getJContentPane() {
              if (jContentPane == null) {
                   jContentPane = new JPanel();
                   jContentPane.setLayout(new BorderLayout());
                   jContentPane.add(getJTextPane(), BorderLayout.CENTER);
              return jContentPane;
          * This method initializes jTextPane     
          * @return javax.swing.JTextPane     
         private JTextPane getJTextPane() {
              if (jTextPane == null) {
                   jTextPane = new JTextPane();
              return jTextPane;
         public void start(){
              File fileDir= new File("somedirectory");
              String strFiles[]= fileDir.list();
              String a="";
              for(int i =0;i<strFiles.length;i++){
                   a=a+strFiles;
              this.jTextPane.setText(a);
    Method init() is irelevant, it just adds JTextPane in applet.
    Method start() is relevant, it runs normaly when started from Eclipse but from browser it sends exception AccessDenied.

  • URGENT: File Adapter List Files operation Issue

    Hi All,
    we are using List files operation in one of the SOA composite which lists all files available in the directory. what we observed files are not listing as for the timestamps.
    is there any property to list all files ascending or descending based on time stamp?. we tried with ListSorter property which is suggested by Oracle,but it works for only INBOUND operations. [http://docs.oracle.com/cd/E23943_01/integration.1111/e10231/adptr_file.htm#BABBIJCJ]
    Any suggestions will be greatly appreciated.

    Hi,
    You can try 2 options:
    1. You would need to capture/collect all the file names, you might have to use BPM and create a separate interface.
    2. You can also pick up those files from the archive directory using FTP and push them using mail adapter.
    Regards,
    Pavan

  • List files stored in a Directory Object

    Hi,
    I looked on Google, on Oracle DB docs and here to find a convenient way to list files stored in a DIRECTORY for batch loading in a table with PL/SQL. But no luck, UTL_FILE doesn't seem to have a method for directory listing. I saw examples with some workaround like putting files list in a text file prior to loading. The directory is feeded by other process and network services, so I don't know the filelist that I need to import and, then delete. I dont have access to the server console and it's impossible for me to dump a kind of «dir» result into a text file. I saw other examples using Java, but it looks like I don't have access to Server Side Java too.
    Is there a simple way to do that in PL/SQL only?
    If not, I'll ask to the DBA the necessary rights to compile/run java on the server side...
    The DB target versions for this requirement are 10g and 11g (mainly) on Windows environment.
    Thanks
    Bruno

    brlav35 wrote:
    The XUTL_FINDFILES seems to be the more convenient way. If that works for you, I certainly have no objection. In a lot of environments, though, that package would be problematic.
    1) It must be installed in the SYS schema. That's generally frowned upon and lots of sites would never allow user code to go into the SYS schema. Chris is a bright guy, so I'm sure the risk of it causing harm is minimal (most likely during an install or upgrade), and it will almost certainly never cause you harm, but that would be a political show-stopper at a lot of places.
    2) The package body is wrapped (if there is a version with the package body in clear text, this point is moot). Again, Chris is a well-respected guy, so I have every confidence that the code is not malicious, but asking a DBA to install a wrapped package you downloaded from the internet into the SYS schema on a production database should generate a crud-load of red flags. This is almost certainly just a theoretical danger, but DBAs and audit compliance regulations care a great deal about theoretical dangers. If someone hacked the web site and uploaded their own wrapped bit of code that had a back door, for example, it would be very hard to catch.
    3) Under the covers, the package is querying one of the undocumented X$ views. Oracle is free to change those views over time, which would potentially cause the package to stop working or stop working correctly in some way. If you're developing code for a system that may be around for a number of years, that becomes a concern. It's unlikely that Oracle will change the particular X$ view that is being referenced here over the lifetime of your code base, but it's more than a trivial concern.
    4) The package is determining what directories a user has access to, that's not Oracle enforcing the restriction. Probably not too big a deal, but it is probably safer from a regulatory compliance standpoint to be able to rely on Oracle the database enforcing privileges rather than relying on a delivered package to enforce those privileges. It's the difference between telling Oracle via specific grants which directories the JVM can access vs. writing your own wrapper that enforces those restrictions. In the end, the restrictions are enforced, but in one case you're relying on the developers of the Oracle database and in the other you're relying on external developers.
    Just to re-iterate-- Chris is a brilliant guy, I don't mean this in any way to impugn him or his code. I am totally confident that his code works, that it works well, and that it will continue to work going forward. My concerns are purely on the political/ regulatory side of things, not on the technical side of things. Technically, I am confident that the code is top-notch.
    Justin
    Edited by: Justin Cave on Sep 9, 2009 12:38 PM
    I wrote this before seeing the last few bits of the exchange where you and Chris already talked about the first point.

  • Can I list files on local drive in tab in a particular sort order?

    I find it useful to have Firefox list files on a local drive or network drive such as:
    file:///u:/captures/
    Is there a way to have it list in the files in a tab in a particular order such as newest to oldest?

    I'm not sure (based on your description) if you did or did not try this already... Most of those network drives have a USB 2.0 port. Have you tried connecting it directly to the computer, and deleting those files? You may also want to do your mass file copy to it connected this way, to speed up the transfer.
    If you are able to do this type of connection with the drive, run Disk Utility. Select the drive in the sidebar and look at the bottom of the Disk Utility window. Note what it says for +Partition Map Scheme+. Then select the volume under the drive in the sidebar. Note what it says for Format. Ideally, for use with Intel Macs, the +partition map scheme+ should be *GUID Partition Table*, and the Format should be *Mac OS Extended* or *Mac OS Extended (Journaled)* (the Journaled part is not that important - it can be turned on and off).
    If the format is something like FAT32 (a Windows PC format), that may be a problem. Although Mac OS X can read from and write to FAT32, I have read that FAT32 has some upper limit on file size, and there may be other issues with copying from a Mac OS formatted volume to a FAT32 volume, such as file name length and naming convention.
    If you want network storage that will work with no hassles, there's the newly refreshed Time Capsules.
    http://store.apple.com/us/product/MB765LL/A/Time-Capsule-1TB?mco=NDkyMTcwMg
    Now with 1TB or 2GB of built-in storage and dual-band wireless networking. The older version without the dual-band wireless at 1TB is available as a refurb for a bit less.
    http://store.apple.com/us/product/FB277LL/A?mco=NDkwNjU0NA
    Perhaps overkill just to get network storage (since a Time Capsule is also a wired/wireless router), but I have an older AirPort Extreme Base Station (basically a Time Capsule without the storage). It is my main router, and I have connected a regular USB 2.0 drive to it for network storage (it has a USB port). It work fine with no hassles. The AirPort Utility is very easy to understand and use.

  • In Health Vault, the Medications are not listed in chronological order, can this be changed?

    I am new to Health Vault and I am entering all my families Medications and Conditions from current backwards.  I am noticing that after I save, logout and return, they are still listed in the same order I entered them in.  This seems crazy, as
    I expected them to be listed in chronological order, with most recent on top.
    Can anyone tell me if there is away to change it so the are listed properly? 
    Thank you

    Hi. Thanks for using HealthVault!
    Currently there is no way to change the sort order of the medication list; you will see the most recently entered item on the top of the list. As a work-around, if you have more past medications to enter, try starting from the earliest ones.
    By the way, if you view the Emergency Profile, it shows only current medications (ie, medications for which you have added an end date).
    We hope to add more flexibility for sorting all types of data. We don't have any specifics on that yet though. Sorry you're having this frustrating experience while we work on that.
    -Kathy-

  • Failing to list files in remote directory using FTP

    Since I've been using a proxy with FTP transport for pull files from a remote server during several months. Now it started to work just sometimes
    ####<Apr 11, 2011 1:33:50 PM BRT> <Error> <WliSbTransports> <WN7-6J6VJN1> <AdminServer> <pool-9-thread-1> <weblogic> <> <f2be7f1e2af484b9:-47b5d228:12f456185e7:-7ff1-000000000000002c> <1302539630973> <BEA-381602> <Error encountered while polling the resource for the service endpoint ProxyService$Infolease$1_0$ProxyServices$Contract$SendBookingConfirmationPS: com.bea.wli.sb.transports.TransportException: <user:davi_diogo>Unable to list files for directory:.
    com.bea.wli.sb.transports.TransportException: <user:davi_diogo>Unable to list files for directory:.
         at com.bea.wli.sb.transports.ftp.connector.FTPWorkPartitioningAgent.execute(FTPWorkPartitioningAgent.java:218)
         at com.bea.wli.sb.transports.poller.TransportTimerListener.run(TransportTimerListener.java:75)
         at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:442)
         at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
         at java.util.concurrent.FutureTask.run(FutureTask.java:139)
         at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:98)
         at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:207)
         at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:909)
         at java.lang.Thread.run(Thread.java:619)
    I configured the service account with my own username, and I do make sure that I have the rights over my home\user directory. (I tested with WINSCP and putty).
    I haven't done any modification to make this start happening.
    following my proxy configuration:
    protocol: ftp
    URI: ftp://myhost/
    mask: *.XML
    but no success.
    I said "sometimes" above because it works after ~15 tentatives. Perhaps this could be a issue in my remote server OS.
    Has anyone faced this issue before?
    Thanks in advance,
    Davinod

    Please refer -
    Error encountered while polling the resource for the service endpoint
    Regards,
    Anuj

  • Commons Net - List files with more than a wildcard "*" in path

    Hello everybody!
    I�m starting to use commons net library in a java project, and I have this doubt: I need to list files in a ftp server, for instance, like this �action*/slot*-qual*.txt�
    i.e., I want to list all the files like �slot (something) � qual (something) .txt�, in all directories beginning with �action (something)�.
    When I put this path in a variable named �path� and pass it to the listFiles method, it returns me a list of zero files. But, for instance, if I only pass the path �action*�, the listFiles returns me all the directories beginning with �action�, like action01, action02, etc. The same happens if I pass only �slot*-qual*.txt�, giving me all the files that respect the command, within a certain directory, like slot1-qual101010.txt, slot2-qual10.txt, slot3-qual1.txt, etc.
    So, there�s must me a method to do this kind of listing, isn�t it? Is it possible to list the files like this?
    If I put the command �ls action*/slot*-qual*.txt� in an ftp client that I use, I get the correct list that I need, so it works like this!
    Thanks a lot everybody!
    Andr� Augusto
    FTPClient ftp;
    FTPFile[] files;
    files=ftp.listFiles(path);
    for (int i=0; i<files.length; i++)
    logger.info("Index: "+i+ " -> Name: " +files.getName());

    Hello everybody!
    I�m starting to use commons net library in a java project, and I have this doubt: I need to list files in a ftp server, for instance, like this �action*/slot*-qual*.txt�
    i.e., I want to list all the files like �slot (something) � qual (something) .txt�, in all directories beginning with �action (something)�.
    When I put this path in a variable named �path� and pass it to the listFiles method, it returns me a list of zero files. But, for instance, if I only pass the path �action*�, the listFiles returns me all the directories beginning with �action�, like action01, action02, etc. The same happens if I pass only �slot*-qual*.txt�, giving me all the files that respect the command, within a certain directory, like slot1-qual101010.txt, slot2-qual10.txt, slot3-qual1.txt, etc.
    So, there�s must me a method to do this kind of listing, isn�t it? Is it possible to list the files like this?
    If I put the command �ls action*/slot*-qual*.txt� in an ftp client that I use, I get the correct list that I need, so it works like this!
    Thanks a lot everybody!
    Andr� Augusto
    FTPClient ftp;
    FTPFile[] files;
    files=ftp.listFiles(path);
    for (int i=0; i<files.length; i++)
    logger.info("Index: "+i+ " -> Name: " +files.getName());

  • Java code to list files in Windows O/S by FIFO sequence

    Hi,
    I am new to java and working on a project which needs to list files from Windows O/S by FIFO sequence.
    Here is the scenario,
    One of the application logs/stores files in Windows System. After that files has to be moved to another files system on AS/400 by FIFO sequence.
    I need to write java program to list files in Windows (by FIFO) and then move to different application running on AS/400.
    I am using java.io.File class and method list() and could able to list all files. But, not able to list files by FIFO sequence.
    I would appreciate to receive any thoughts implementing FIFO for listing files using java.
    Thanks,
    Siva

    Duplicate post, replied to here:
    http://forum.java.sun.com/thread.jspa?threadID=5169767&messageID=9652068#9652068

  • Listing files on FMS server @ client

    Hi Everybody!
    I want to show list of FLV files placed on FMS server. do u
    guys have any sample code for that. Looking forward for reply!
    thanks.

    Amitpal,
    Here is a server side class that list files in 3 ways.
    getFiles just returns the content of the folder specifiec.
    showFileList returns the content of a folder listing it's
    sub-folders and content as an object.
    listFiles just returns the recursive sort of the folder.
    function FileManager()
    trace("#FileManager# constructor");
    FileManager.prototype.getFiles = function(p_client, p_path)
    trace("getFiles Called");
    trace(p_path)
    var fileList = new File(p_path);
    var temp = fileList.list();
    return temp;
    FileManager.prototype.showFileList = function(p_client,
    p_path)
    this.fileList = {folders:"", files:""};
    this.folders = new Array();
    this.files = new Array();
    this.listFiles(p_path, true);
    //for(j=0; j<this.fileList.length; j++){
    // trace(this.fileList[j]);
    this.fileList.folders = this.folders;
    this.fileList.files = this.files;
    return this.fileList;
    FileManager.prototype.listFiles = function(path, listsub)
    var curFolder = new File(path);
    var files = curFolder.list();
    for (var f=0; f < files.length; f++) {
    if (files[f].isDirectory && listsub == true) {
    this.folders.push(files[f].name)
    //this.listFiles(files[f].name, true);
    } else {
    this.files.push(files[f].name);
    // main.asc file
    load("FileManager.asc");
    application.onAppStart = function()
    this.fileManager = new FileManager();
    // FileManager Call *from Peldi
    Client.prototype.fileManagerCall = function(p_method)
    var fileMgr = application.fileManager;
    if (fileMgr[p_method] == undefined) {
    trace("ERROR: this.fileManager." + p_method + " method not
    found");
    return false;
    } else {
    var params = new Array();
    params.push(this);
    for (var i=1; i<arguments.length; i++)
    params
    =arguments;
    var res = fileMgr[p_method].apply(fileMgr, params);
    return res;
    //client side
    // onConnect event handler for NetConneciton
    public function onConnect(evt:Object)
    __nc["Application"] = this;
    var resultObject = new Object();
    resultObject["owner"] = this;
    resultObject.onResult = function(returnValue){
    //set client side object
    this.owner.__fileList:Object = {};
    this.owner.__fileList = returnValue;
    this.owner.dispatchEvent({type:"connectSuccess",
    nc:this.owner.__nc});
    // Call fms passing the video folder as a path
    __nc.call("fileManagerCall", resultObject, "showFileList",
    "folderOfVideos");
    // a setter method to store the fileList
    public function set fileList(p_list):Void
    __fileList = p_list;
    var foldArr = [];
    for (var i = 0; i<__fileList["folders"].length; i++) {
    foldArr.push(getFolder(__fileList["folders"]
    this.lessonArray = foldArr;
    var vidArr = [];
    for (var j = 0; j<__fileList["files"].length; j++) {
    vidArr.push(getFile(__fileList["files"][j]));
    this.videoArray = vidArr;
    // helper methods
    private function getFolder(p_folder):Object
    trace(p_folder)
    var foldObj = {label:"", data:""};
    var filePath =
    p_folder.substr((p_folder).lastIndexOf("/")+1);
    foldObj.label = filePath;
    foldObj.data = p_folder;
    return foldObj;
    private function getFile(p_file):Object
    var vidObj = {label:"", data:""};
    var vidFilePath = p_file.substr((p_file).lastIndexOf("/")+1);
    var vidFile = vidFilePath.substr(0,
    vidFilePath.indexOf("."));
    vidObj.label = vidFile;
    vidObj.data = vidFile;
    return vidObj;
    Hope this helps...
    Shack

  • Listing file of remote user

    I going to develop FTP program.. but i have a problem in listing file of remote user.. any ideas?

    You can use FTPBean
    http://www.geocities.com/SiliconValley/Code/9129/javabean/ftpbean/

Maybe you are looking for

  • Creating a smart folder with Terminal?

    What I'm trying to do might not be possible, which wouldn't surprise me at all. What I'd like to do is one of the following: 1. Create a smart folder that contains everything in the "/" folder. 2. Create a smart folder that is populated with every vo

  • Differences between Monitor and Decrypt actions in Decryption Policies

    Hi Everybody, Currently I'm working in my first WSA (S170) implementation and some questions has popped up while I was configuring the Decryption policies. The main question here is: What are the differences between "monitor" and "decrypt" in the URL

  • BEX WAD 7.0:  Chart Takes Long Time to Display in Portal - Query runs FAST

    I have a BEx WAD 7.0 template which contains 3 column charts (each with it's own seperate DataProvider/Query).  When the page loads...two of the charts show up right away, but one of them takes almost a minute to display on the screen (I thought it w

  • Post shipment Charges.

    Hi friends, We have an issue to handel the post shipment charges as follows, Please suggest if you have any solution. In a Typical Export consignment, there are various post delivery charges after the Delivery is created  ex: Inspection charges, fumi

  • Chaging description by the approver causes worng behaviour of workflow

    Hello, When approver makes changes to the SC "descritption" of SC and approves the SC is routed back to requistioner for accept/reject changes as well as appear in inbox the first approver for his approval. Error reporoduction Create a SC, single ite