Discussion Board

Results 1 to 2 of 2
  1. #1
    Regular Contributor divyas's Avatar
    Join Date
    Oct 2005
    Posts
    54
    hi ,

    I am trying to make a list where the items in the list would come fron the filenames which lie inside a given folder.So for that i will have to indentify the number of files in the given folde and the names of these files.
    All this has to be done dynamically .........

    Please help me by telling how can i parse the folder to determine the number of files inside it and their name.
    Is their any function or some Api which can be used.

  2. #2
    Super Contributor Jason Glass's Avatar
    Join Date
    Mar 2006
    Location
    Phoenix, AZ. USA
    Posts
    556
    Code:
    To list the content of a directory that your FileConnection is pointing to:
    Enumeration e = fc.list();
    while (e.hasMoreElements()) {
     System.out.println(((String)e.nextElement()));
    }
    This method returns an enumeration of all directories and files that are present in the directory. Directories are denoted with a trailing slash "/" in their returned name.

    then while inside of while loop, create a fileconnection to each element, once created, get its name, and pertinent info
    Jason Glass
    http://IChiBanComputers.Com

Similar Threads

  1. Folders in listbox
    By jrantam in forum Symbian User Interface
    Replies: 2
    Last Post: 2008-10-10, 11:44
  2. how to parse the xml? anyone use the SyExpat?
    By ipis in forum Symbian C++
    Replies: 11
    Last Post: 2007-02-28, 04:16
  3. probelm with hiding folders in messaging system
    By chishti.hameed in forum Symbian Networking & Messaging (Closed)
    Replies: 0
    Last Post: 2006-03-02, 13:40
  4. Get the folders and the messages in "Documents"
    By bernie31 in forum Symbian Networking & Messaging (Closed)
    Replies: 0
    Last Post: 2006-01-19, 18:07
  5. Accesing Nokia Pc Suite Folders URGENT
    By tarunnasa in forum PC Suite API and PC Connectivity SDK
    Replies: 1
    Last Post: 2004-08-21, 03:01

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved