URGENT!! File Upload Utility or a Custom File Upload UI is needed

Hi all,
I'm trying to find or develop a file upload utility or custom user interface rather than editing and adding file type item to a page. There is a free portlet for file upload in Knowledge Exchange resources, but it is for 3.0.9 release. I'm using portal 9.0.2.
I could not any sample about the new release. Also API such as wwsbr_api that is used to add item to content areas is out dated.
I create a page with a region for "items". When "edit" page and try to add an "file" type item the generated url is sth like this;
"http://host:7779/pls/portal/PORTAL.wwv_additem.selectitemtype****"
After selecting item type as a simple file autogenerated url is sth. like ;
"http://host:7779/pls/portal/PORTAL.wwv_add_wizard.edititem"
I made search about these API but could not find anything (in PDK PL/SQL API help, too).
I need this very urgent for a proof of consept study for a customer.
Thanks in advance,
Kind Regards,
Yeliz Ucer
Oracle Sales Consultant

Answered your post on the General forum.
Regards,
Jerry
PortalPM

Similar Messages

  • URGENT! File Upload Utility or a Custom UI for File Upload is needed!

    Hi all,
    I'm trying to find or develop a file upload utility or custom user interface rather than editing and adding file type item to a page. There is a free portlet for file upload in Knowledge Exchange resources, but it is for 3.0.9 release. I'm using portal 9.0.2.
    I could not any sample about the new release. Also API such as wwsbr_api that is used to add item to content areas is out dated.
    I create a page with a region for "items". When "edit" page and try to add an "file" type item the generated url is sth like this;
    "http://host:7779/pls/portal/PORTAL.wwv_additem.selectitemtype****"
    After selecting item type as a simple file autogenerated url is sth. like ;
    "http://host:7779/pls/portal/PORTAL.wwv_add_wizard.edititem"
    I made search about these API but could not find anything (in PDK PL/SQL API help, too).
    I need this very urgent for a proof of consept study for a customer.
    Thanks in advance,
    Kind Regards,
    Yeliz Ucer
    Oracle Sales Consultant

    Answered your post on the General forum.
    Regards,
    Jerry
    PortalPM

  • Using Win 7, I cannot utilize the "Folder Options" "File Types" utility to add/change file properties

    I am trying to use a batch file that worked perfectly on my WinXP system to create "shntool.txt" reports of my music files - usually .flac, and sometimes .shn - listing file time duration, size, etc.
    When I try to copy the batch files onto my WinXP system, I get all sorts of error reports that prohibit me from generating those text files. This is an example of such a batch file ("shntool-flac.bat) that always worked in the past.
    "cls
    shntool len *.flac > C:\Burning\shntool.txt
    :: cmg 4/18/2001
    :: the syntax above uses the new parameter style,
    :: previous ver was "shntool len -u mb *.shn".
    :: alternately, you may use other params,
    :: such as "shntool -len -mb -debug *.shn" for more info.
    :: see "shntool -len -h" for specific help on the '-len' params.
    pause
    exit"
    The error message includes "shntool: fork: No such file or directory
    shntool [len: error: error while forking child process. see above"
    I downloaded "FileTypesMan" which allowed me to make some changes in the file menus (e.g., "Enqueue in Winamp, Play in Winamp," but I CAN'T get "shntool-flace.bat" and "shnlen-flac.bat" to work for the reasons list
    above.
    I would be grateful for any assistance here. Thanks in advance.
    Because I am new to this forum, please re-direct my question if this isn't the proper forum.

    kglad,
    Thanks for the suggestion but I have attempted this many times to no avail. As I said in my original post, "I have researched this problem on this forum and the Adobe site and believe that I have tried everything over the past week."
    It is very late here (I am in Greece). I will have a further attempt in the morning. The windows machine is hut down. Thanks for your help.
    Bob

  • Can I create an automatic custom file save name/path once I click digital signature field?

    Hi,
    What I'm trying to do is once I click on a digital signature and I add my digital signature it requires me to sign it.  I want to know if there's a workaround to where once I click it it will automatically save to a file name based on a field and to a pre-determined directory?  Say, if I want it to save to a users desktop.  My supervisor is wanting to eliminate his employees having to change the file name to the format he wants and selecting the save location and make it automatic for everyone to have it saved at the same location on their computers. 
    Will likely have everyone in the office create a folder named 'Leave Requests'.  This will be the location on the desktop where all these automatically saved files would go.  The custom file name would be Emp_Name + "Leave Request" + Date where Emp_Name and Date are 2 variables that are user inputted field values on the form.  I have looked around but there doesn't seem to be too much on this one.  I do realize I can't create a custom 'Save As' location and path name but I have read a little about creating a custom automatic save feature and wanted to know if I could implement that.  Here is the information I read about:
    http://acrobatusers.com/tutorials/print/how-save-pdf-acrobat-javascript
    I appreciate all help any of you can give me in this matter.  Thanks!!!

    This tutorial is great!
    http://mydesignpad.com/create-a-complex-html-email-signature-for-mail-on-mac-os- x-10-9-mavericks

  • Use of Custom Files in Veristand

    Hello All,
       Haven't been able to find much documentation related to use of "Custom Files" in Veristand.  Would like to know of any examples of file types users have implemented.  Specifically, I would like to know if you can "call" certain file types from the models or custom devices (i.e. for configuration parameters or databases). 
    Thanks much,
    GSinMN  
    Solved!
    Go to Solution.

    Howdy GSinMN,
    There is a bit of documentation in the VeriStand Help that discusses Custom Files specifically.
    Adding Custom Files
    http://zone.ni.com/reference/en-XX/help/372846D-01/veristand/add_custom_files/
    Although, the help doesn't quite reveal the full capabilities of this feature. There are two distinct use cases I have been able to identify for the Custom Files option in VeriStand. I will list them out in more detail and show you an example.
    Making Files easily accessible to the Operator in the development environment.
    When a file is added into the Custom Files section of the Project it will have its own icon in the project and will be included in the project dependencies. Having the file brought to view in the project is helpful if there is a troubleshooting image or specific document (calibration specs, steps for running a test, etc) that you would like your Operator to have access to. For example, in the example project I've included, there is a file added called "TestA1_PreTestSetup.txt". From the project (on the toolbar) the Operator has the option to "Open File" (to view it) or "Export..." to investigate its path on the operator machine.
    Please note that the file is also now added to the dependencies of the project.
    If you begin to investigate the file in the project and lets say you right-click on it and notice that there is a Properties option. You may notice that the Description for this file is empty. This can actually be populated being modifying the XML source of the .nivsproj. This also leads into the second use case for Custom Files.
    Transferring files to the RT target which can be used by the VeriStand Engine.
    If you were to investigate the .nivsproj XML you could first find the Custom Files section, and then the tags for the item you configured.
    Here are the relevant tags and a break down,
    <DependentFile> - This points to the source of the custom file. In this circumstance, I have added the file to the "C:\Users\Public\Documents\National Instruments\NI VeriStand 2011\Test Procedures" directory. It is able to resolve the the first component to "To Common Doc Dir" because this is the common directory for VeriStand, and then it appends the Test Procedures folder and name of the file that I created.
    <Description> - Populating this tag gives us the ability to fill in the description information that occurs when we right click the file in the project.
    <RTDestination> - Populating this tag gives you the ability to also send the File to the target upon deployment. Your VeriStand engine could then access this file during operation. As far as which types of files to use, the link in the post above should help guide that.
    Please Note: Modifying the XML of the project gives you added customization and functionality to your project but these modifications should not be done heedlessly. Incorrectly modifying the tags in the XML file can lead to improper performance and outcomes. So tread carefully and make only minor changes at a time.
    I hope this helps. Have a great day, GSinMN
    Tim A.
    National Instruments
    Attachments:
    Custom Files Example.zip ‏10 KB
    TestA1_PreTestSetup.txt ‏1 KB

  • Unable to install File Upload Utility in AIX system

    Hello,
    I installed the Forms File Upload Utility, through CGI, following the steps described in the html
    document provided with the utility. That is:
    - i copied the files UploadClient.jar.sig and UploadServer.jar to the directory
    /ias102/6iserver/forms60/java;
    - i edited the .profile file, for the variable CLASSPATH to include the forms60/java directory:
    CLASSPATH=/ias102/6iserver/forms60/java:/ias102/6iserver/forms60/java/UploadServer.jar:/ias102/6iserver/discwb4/classes/locator.jar:/usr/java131/jre/lib/rt.jar:
    - i edited the .profile file, for the variable PATH to include the requested directories (Forms \bin and \bin\classic):
    PATH=/ias102/6iserver/lib:/ias102/6iserver/bin:/usr/java131/jre/bin/classic/:/us
    r/java13
    1/bin:$PATH
    (i also tried editing the CLASSPATH and PATH variables in the forms60.sh and forms60_server files)
    - on my machine (client machine) i installed the PJC.x509 certificate;
    After this installation, i included the Demo Form provided with the utility in my test application, and then i executed
    the form.
    I tried to upload a file but i got the following error: "FRM-40735: WHEN-BUTTON-PRESSED trigger raised unhandled exception ORA-06508"
    I looked in the html document, in the "Troubleshooting" section, and i did a test pressing
    the Key-Listval (Control+L by default), that would pop up a dialog containing
    the current CLASSPATH, but instead i got the following error:
    "FRM-40735: KEY-LISTVAL trigger raised unhandled exception ORA-105100."
    In the html said that "If this fails then this is because Forms cannot instanciate any Java code
    at all".
    Do i need to add any more environment settings?
    Thanks, Jorge

    There are probably several environment variables which need to be set in order for the Forms runtime to communicate with Java. However, to where they point will depend on which Java home you choose to use. For Forms 6.x, you must use the equivalent of JDK 1.1.8 or 1.2.2. These versions are included in the Oracle home. If you try using a newer version (like the one installed on the OS) you will likely have problems.
    Verify these env variables point to the appropriate locations to use the jdk/jre in the Oracle Home:
    PATH
    CLASSPATH
    LIBPATH
    LD_LIBRARY_PATH
    JAVA_HOME
    Additionally, ensure that your CLASSPATH includes references to the following jar files:
    importer.jar
    rt.jar

  • Ifweb60.exe crash when using file upload utility

    Hello,
    I have implemented the file upload utility in my own forms. When using the file upload for the first time in my forms session everything works fine. But when i try to start it again (within the same forms session) i get an ifweb60.exe crash on the server and a FRM-92101 error on the forms client
    Did anybody have the same problem before and how can i solve this?
    I am using iAS9i (release 1.0.2.1.0) with forms patch 10 (Jinitiator 1.3.1.9), Oracle server 8.1.7 on Windows NT 4.
    I included the output of my java console
    Thanks,
    Gerton
    Oracle JInitiator: Version 1.3.1.9
    Using JRE version 1.3.1.9 Java HotSpot(TM) Client VM
    User home directory = C:\WINNT\Profiles\382
    Proxy Configuration: Manual Configuration
    Proxy: MyProxy
    Proxy Overrides: <local>
    JAR cache enabled
    Location: C:\WINNT\Profiles\382\Oracle Jar Cache
    Maximum size: 50 MB
    Compression level: 0
    c: clear console window
    f: finalize objects on finalization queue
    g: garbage collect
    h: display this help message
    l: dump classloader list
    m: print memory usage
    q: hide console
    s: dump system properties
    t: dump thread list
    x: clear classloader cache
    0-5: set trace level to <n>
    Loading http://80nte/forms60java/f60all_jinit.jar from JAR cache
    Loading http://80nte/forms60java/UploadClient.jar.sig from JAR cache
    Loading http://80nte/forms60java/ctb_icons.jar from JAR cache
    connectMode=HTTP, native.
    Forms Applet version is : 60819
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Start setProperty
    Start setProperty
    Start setProperty
    Opening connection to http://80nte:80/download/907.doc...
    Copying resource (type: application/msword, modified on: Mon Aug 05 11:45:58 CEST 2002)...
    35840 byte(s) copied...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Start setProperty
    Start setProperty
    Start setProperty
    Client OS is Windows NT
    start RunCMD...: cmd.exe /C C:\TEMP\907.doc
    Opening Word document...
    Document has been released C:\TEMP\907.doc
    FileUploader: LoadFile : Named File
    FileUploader: 907.doc
    FileUploader: Dir>C:\TEMP\
    FileUploader: Named File = C:\TEMP\907.doc exists
    FileUploader: <PERFORM UPLOAD>
    FileUploader: Filesize 35840
    FileUploader: Source file size before encoding 35840 Bytes; (Compressed to 8905 Bytes)
    FileUploader: Size of encoded byte array : 12190 (3 Chunks)
    FileUploader: numchunks is 2
    FileUploader: Chunking : 0:4096
    FileUploader: Dispatch Chunk 1
    FileUploader: Chunking : 4096:8192
    FileUploader: Dispatch Chunk 2
    FileUploader: Chunking : 8192:12190
    FileUploader: Dispatch Chunk 3
    FileUploader: </PERFORM UPLOAD>
    Start setProperty
    Start setProperty
    Start setProperty
    Start setProperty
    Opening connection to http://80nte:80/download/907.doc...
    Copying resource (type: application/msword, modified on: Mon Aug 05 11:46:41 CEST 2002)...
    35840 byte(s) copied...
    Start setProperty
    Onbekende setProperty...
    Start setProperty
    Start setProperty
    Start setProperty
    Start setProperty
    Client OS is Windows NT
    start RunCMD...: cmd.exe /C C:\TEMP\907.doc
    Opening Word document...
    Opening Word document...
    Document has been released C:\TEMP\907.doc
    FileUploader: LoadFile : Named File
    FileUploader: 907.doc
    FileUploader: Dir>C:\TEMP\
    FileUploader: Named File = C:\TEMP\907.doc exists
    FileUploader: <PERFORM UPLOAD>
    FileUploader: Filesize 35840
    FileUploader: Source file size before encoding 35840 Bytes; (Compressed to 8917 Bytes)
    FileUploader: Size of encoded byte array : 12206 (3 Chunks)
    FileUploader: numchunks is 2
    FileUploader: Chunking : 0:4096
    FileUploader: Dispatch Chunk 1
    FileUploader: Chunking : 4096:8192
    FileUploader: Dispatch Chunk 2
    FileUploader: Chunking : 8192:12206
    FileUploader: Dispatch Chunk 3
    FileUploader: </PERFORM UPLOAD>
    oracle.forms.net.ConnectionException: Forms session <7> aborted: unable to communicate with runtime process.
         at oracle.forms.net.ConnectionException.createConnectionException(Unknown Source)
         at oracle.forms.net.HTTPNStream.getResponse(Unknown Source)
         at oracle.forms.net.HTTPNStream.doFlush(Unknown Source)
         at oracle.forms.net.HTTPNStream.flush(Unknown Source)
         at java.io.DataOutputStream.flush(Unknown Source)
         at oracle.forms.net.StreamMessageWriter.run(Unknown Source)

    Problem is solved!

  • Custom File Accesor implementation in 6.1 MP1

    I have made an custom file accessor (IPTCustomFileAccessor) using the Portal Server API for a crawler that is crawling a news website. I found example of the implementation of a custom file accessor to ALI version 5 but it seems that it does not go the same way in version 6.1.
    Here is what I have done:
    1. copied my custom accessor .jar file to <PORTAL_HOME>\accessors\customfa.jar2. Created accesors.xml to <PORTAL_HOME>\settings\config with following content:
    <accessorlibs>
    <accessorlib name="sampleaccessor" path="accessors/" />
    </accessorlibs>3. After that restarted the Portal. When the portal is starting it gives me some error about 5.0 configs not suitable in 6.1
    After that I tried to use the 6.1's dynamic loads:
    1. I created a new folder named accessors to <PT_HOME>\settings\portal\dynamicloads and moved the accessors.xml to that location
    2. Restarted the portal and then I get an error message:
    1559     portal.xxxx.xxx     8-22-2007     10:57:56.250     Fatal     UI_Infrastructure     Thread-0     com.plumtree.uiinfrastructure.application.startup.LoadCustomLoads     Fatal Exception loading lib file: c:\bea\alui\settings\portal\dynamicloads\Accessors\accessors.xml
    com.plumtree.openfoundation.util.XPNullPointerException: XPDynamicDiscovery failed to find all needed information in the xml file: c:\bea\alui\settings\portal\dynamicloads\Accessors\accessors.xml. Please make sure that the file is formatted correctly.Does anyone have a clue how should the accessors.xml be formatted? Thanks in advance!
    Greets,
    Nils-Erik Siren

    SSO info - as well as most other portal config info that used to be in various XML files - was moved to $PT_HOME/settings/portal/portalconfig.xml in G6.
    john

  • How to avoid the split problem when uploading the data from csv file

    Dear Friends,
                  I have to upload data from the .csv file to my custom table , i have found a problem when uploading the data .
    i am using the code as below , please suggest me what i have to do in this regard
          SPLIT wa_raw_csv  AT ',' INTO
                    wa_empdata_csv-status
                     wa_empdata_csv-userid
                     wa_empdata_csv-username
                     wa_empdata_csv-Title
                     wa_empdata_csv-department.
    APPEND wa_empdata_csv TO  itab.
    in the flat file i can see for one of the record for the field Title  as
    Director, Finance - NAR............there by through my code the  wa_empdata_csv-Title is getting splited data as "Director, and  Department field is getting Finance - NAR" , i can see that even though  " Director, Finance - NAR"  is one word it is getting split .
    .......which is the problem iam facing.Please could any body let me know how in this case i should handle in my code that this word
    "Director,Finance - NAR"   wil not be split into two words.
    Thanks & Records
    Madhuri

    Hi Madhuri,
    Best way to avoid such problem is to use TAB delimited file instead of comma separated data. Generally TAB does not appear in data.
    If you are generating the file, use tab instead of comma.
    If you cannot modify the format of file and data length in file is fixed character, you will need to define the structure and then move data in fixed length structure.
    Regards,
    Mohaiyuddin

  • Getting "Warning: The file upload failed.No such file or directory." while trying to upload image using af:inputFile

    Hi,
    I have a <af:inputFile> component which will upload only image file and render  the corresponding image...
    It work with normal application deployed on weblogic server however when i use same taskflow as a part of human task in SOA BPM worklist...
    I get this warning message "Warning: The file upload failed.No such file or directory." for certain files where as it works for certain image files.
    And in BPM whenever i upload PNG file it throws this error.
    Please help.

    For some files like Images with .png extensions it gives following error :
    java.io.IOException: No such file or directory
      at java.io.UnixFileSystem.createFileExclusively(Native Method)
      at java.io.File.checkAndCreate(File.java:1705)
      at java.io.File.createTempFile0(File.java:1726)
      at java.io.File.createTempFile(File.java:1803)
      at org.apache.myfaces.trinidadinternal.config.upload.UploadedFileImpl._createOutputStream(UploadedFileImpl.java:284)
      at org.apache.myfaces.trinidadinternal.config.upload.UploadedFileImpl.loadFile(UploadedFileImpl.java:208)
      at org.apache.myfaces.trinidadinternal.config.upload.CompositeUploadedFileProcessorImpl._processFile(CompositeUploadedFileProcessorImpl.java:344)
      at org.apache.myfaces.trinidadinternal.config.upload.CompositeUploadedFileProcessorImpl.processFile(CompositeUploadedFileProcessorImpl.java:95)
      at org.apache.myfaces.trinidadinternal.config.upload.FileUploadConfiguratorImpl._doUploadFile(FileUploadConfiguratorImpl.java:329)
      at org.apache.myfaces.trinidadinternal.config.upload.FileUploadConfiguratorImpl.beginRequest(FileUploadConfiguratorImpl.java:162)
      at org.apache.myfaces.trinidadinternal.config.GlobalConfiguratorImpl._startConfiguratorServiceRequest(GlobalConfiguratorImpl.java:610)
      at org.apache.myfaces.trinidadinternal.config.GlobalConfiguratorImpl.beginRequest(GlobalConfiguratorImpl.java:216)
      at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:155)
      at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
      at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
      at oracle.bpel.services.workflow.client.worklist.util.WorkflowFilter.doFilter(WorkflowFilter.java:175)
      at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
      at oracle.bpel.services.workflow.client.worklist.util.DisableUrlSessionFilter.doFilter(DisableUrlSessionFilter.java:70)
      at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
      at oracle.adf.library.webapp.LibraryFilter.doFilter(LibraryFilter.java:180)
      at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
      at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:119)
      at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:324)
      at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:460)
      at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:103)
      at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:171)
      at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)
      at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
      at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:163)
      at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
      at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
      at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
      at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3730)
      at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3696)
      at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
      at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
      at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2273)
      at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2179)
      at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1490)
      at weblogic.work.ExecuteThread.execute(ExecuteThread.java:256)
      at weblogic.work.ExecuteThread.run(ExecuteThread.java:221)

  • Custom File Finder

    Hi everyone,
    I am trying to build a custom file finder to search for my mp3 files on my computer. As you can see my nickname, I am a DJ, so I have lots of mp3 files on many directories on my PC and sometimes it's difficult for me to find the song I am looking for. I want to take advantage of JAVA to build my file finder. I am planning on having two command line arguments. One with the path string and another with the filename and extension. (Just in case I want to use to find other files than .mp3 such as .wma, and .avi.)
    If you guys have any ideas how I can do this, please let me know. Also, if you have any example or references I can study from, I will really appreciate it.
    Thanks in advance.

    Like I said before, I was trying to write a code to search for files on my computer. The program would ask me for the path, and also for the filename and its extension. After that, the program would scan the whole directory and after the whole directory was scanned, I would get a list of all the files in there and the path of the file I was looking for. (only if the file was found.)
    After reading the file class, I got this code but I am not getting the path for the file. I only get the list of all the files on the directory. I think I got a logical error somewhere because the program is compiling and I am not getting run-time errors.
    If anyone have any suggestions on how I can fix my code or knows how to improve it, please let me know.
    Thanks in advance.
    import java.util.*;
    import java.io.*;
    public class FileFind
        static final int      MAX_DEPTH  = 20;  // Max 20 levels (directory nesting)
        static final String   INDENT_STR = "   ";                 // Single indent.
        static final String[] INDENTS    = new String[MAX_DEPTH]; // Indent array.
        static boolean done = false;
        static String found = "not found";
        //===================================================================== main
        public static void main(String[] args)
            //... Initialize array of indentations.
            INDENTS[0] = INDENT_STR;
            for (int i = 1; i < MAX_DEPTH; i++) {
               INDENTS[i] = INDENTS[i-1] + INDENT_STR;
            System.out.println("Enter the directory you want to search.");
            System.out.println("Do not use quotations marks. Use \\ instead of \"");
            Scanner input = new Scanner(System.in);
            File dir = new File(input.nextLine());
            //===============================================
            System.out.println("Enter the file name and its extension");
            System.out.println("Do not use quotations marks.");
            File filename = new File(input.nextLine());
            if (dir != null && dir.isDirectory()) {
                listRecursively(dir, 0);
                //====================
                if(dir.getName().equals(filename.getName())){
                     done = true;
                     found = filename.getPath();
                //=============
            } else {
                System.out.println("Not a directory: " + dir);
            //======
            if(done == true){
                   System.out.println("The file's path is: "  + found);
              //=====
        //========================================================== listRecursively
        public static void listRecursively(File fdir, int depth)
            System.out.println(INDENTS[depth] + fdir.getName());  // Print name.
            if (fdir.isDirectory() && depth < MAX_DEPTH) {
                for (File f : fdir.listFiles()) {  // Go over each file/subdirectory.
                    listRecursively(f, depth+1);
    {code}
    Edited by: DJFONSO on Nov 10, 2007 10:12 PM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Custom file chooser

    Hello,
    I need to design a custom file chooser. Infact, I cannot call it a file
    chooser, because this is not accessing local system files. I am uploading
    some files into a directory using ASP and I keep that file name in the database.
    I can even upload directores and directores with files too into the database.
    I need to display those files and folders in the "what is called as file chooser".
    The List should work as it works in file chooser. i.e when I click on a folder,
    it should show the files inside it. When I click on the file, the file should
    be selected. Infact there is nothing in the file. Its all virtual only. Its only
    the name that is selected.
    I should be given an option to select "directories only" also.
    The "file chooser" should not have show files of type, just the file name
    text field only. The combobox should display "user added" string message. And
    this is only one item in the combobox. I should be able to create folders, show
    lists,etc... as it appears in the file chooser. (buttons beside the combobox)
    Any ideas would be greatly appreciated.
    Thanks

    ok, this is just an example....you'll probably need a different constructor and additional methods....
    public class VirtualFile{
      private String file ;
      private VirtualFile[] children;
      private VirtualFile parent;
      public VirtualFile(String file,VirtualFile parent,VirtualFiles[]children){
         this.file = file;
         this.parent = parent;
         this.children = children;
      public boolean isRoot(){
        return parent == null;
      public boolean isDirectory(){
        return children = null || children.length==0;
      public VirtualFile[] getChildren){
        return children;
    }

  • Custom File Processor implementing UploadedFileProcessor

    I am implementing a custom file processor since upload of files will be in GB, Faces Context is not available it gives NULL also the ServletRequest Object available seems to be a trimmed instance as it not could list any parameter values..
    Any idea on how to read parameter from request inside that class or to get to FacesContext?

    Hi Bowen,
    Here's the example DataPlugin closest to what you're describing.
    You can also look at Exercise 5 from the DIAdem Hands-On, posted here:
    http://www.ni.com/example/30393/en/
    Brad Turpin
    DIAdem Product Support Engineer
    National Instruments

  • How to add custom file icons on SharePoint 2010 document library?

    Hi there,
    In a document library SharePoint shows the PDF and Word etc icons all fine - however we have a custom file format with a custom icon. Is this possible to add this custom icon for our custom extension? How?
    Thank you so much.

    Hi,
    You could accomplish your requirement by using jQuery with these steps, and this code is using jQuery to modify it on the current page, if you would like to make it work on all library, you need to choose the former method or add this JQuery script on all
    library pages manually:
    Upload a custom icon to file “14\ Template\Images” or your SharePoint document library.
    Add this code below in the document library that you want to extend your custom icon, you could add code by following these: Click edit page in the document library -> add a web part -> choose Content Editor -> click edit source in the Ribbon ->
    add the source below -> click OK.
    <script src="https://code.jquery.com/jquery-1.11.1.min.js" type="text/javascript"></script><script type="text/javascript">
    $(document).ready(function(){
    var fileObject = $("[title$='docx']");
    for(var i=0; i < fileObject.length; i++){
    //fileObject[i].outerHTML="<img width=\"16\" height=\"16\" title=\"test.docx\" alt=\"test.docx\" src=\"/_layouts/15/images/custom.png\" border=\"0\">"; // upload your custom icon to file ” 14\ Template\Images”, replace your src URL
    fileObject[i].outerHTML="<img width=\"16\" height=\"16\" title=\"test.docx\" alt=\"test.docx\" src=\"/sites/sharepoint2013/Shared%20Documents/custom.png\" border=\"0\">"; // upload your custom icon to SharePoint document library, replace your src URL
    </script>
    The screenshot below is my result:
    Best Regards
    Vincent Han
    TechNet Community Support

  • How to upload a Flat file into sap database if the file is in Appl'n Server

    Hello Sap Experts , Can you tel me
    " How to upload a Flat file into sap database if the file is in Application Server.
    what is Path for that ?
    Plz Tel Me its Urgent
    Thanks for all

    Hi,
    ABAP code for uploading a TAB delimited file into an internal table. See code below for structures.
    *& Report  ZUPLOADTAB                                                  *
    *& Example of Uploading tab delimited file                             *
    REPORT  zuploadtab                    .
    PARAMETERS: p_infile  LIKE rlgrap-filename
                            OBLIGATORY DEFAULT  '/usr/sap/'..
    DATA: ld_file LIKE rlgrap-filename.
    *Internal tabe to store upload data
    TYPES: BEGIN OF t_record,
        name1 like pa0002-VORNA,
        name2 like pa0002-name2,
        age   type i,
        END OF t_record.
    DATA: it_record TYPE STANDARD TABLE OF t_record INITIAL SIZE 0,
          wa_record TYPE t_record.
    *Text version of data table
    TYPES: begin of t_uploadtxt,
      name1(10) type c,
      name2(15) type c,
      age(5)  type c,
    end of t_uploadtxt.
    DATA: wa_uploadtxt TYPE t_uploadtxt.
    *String value to data in initially.
    DATA: wa_string(255) type c.
    constants: con_tab TYPE x VALUE '09'.
    *If you have Unicode check active in program attributes then you will
    *need to declare constants as follows:
    *class cl_abap_char_utilities definition load.
    *constants:
    *    con_tab  type c value cl_abap_char_utilities=>HORIZONTAL_TAB.
    *START-OF-SELECTION
    START-OF-SELECTION.
    ld_file = p_infile.
    OPEN DATASET ld_file FOR INPUT IN TEXT MODE ENCODING DEFAULT.
    IF sy-subrc NE 0.
    ELSE.
      DO.
        CLEAR: wa_string, wa_uploadtxt.
        READ DATASET ld_file INTO wa_string.
        IF sy-subrc NE 0.
          EXIT.
        ELSE.
          SPLIT wa_string AT con_tab INTO wa_uploadtxt-name1
                                          wa_uploadtxt-name2
                                          wa_uploadtxt-age.
          MOVE-CORRESPONDING wa_uploadtxt TO wa_upload.
          APPEND wa_upload TO it_record.
        ENDIF.
      ENDDO.
      CLOSE DATASET ld_file.
    ENDIF.
    *END-OF-SELECTION
    END-OF-SELECTION.
    *!! Text data is now contained within the internal table IT_RECORD
    * Display report data for illustration purposes
      loop at it_record into wa_record.
        write:/     sy-vline,
               (10) wa_record-name1, sy-vline,
               (10) wa_record-name2, sy-vline,
               (10) wa_record-age, sy-vline.
      endloop.

Maybe you are looking for

  • How i  'fixed' my ipod due to the itunes problem

    Okay, many of you have the same problem as i had, where suddenly the computer\itunes\updater wont detect your ipod. These are the steps i took to finally solve my problem this morning. -Try restarting Ipod by turning hold switch on/off and pressing d

  • White default background color in indesign pdf file

    When I export in indesign cs6 pdf file (I made a digital flipbook and I want to upload it on my website) there is a white default color in the background. Is there a way to get rid of this white default color or make it transparent in indesign?

  • Photoshop CS5.1 brush scroll panel issue

    Hello everyone, Since last week I've been getting problems with photoshop. The brush panel has problems with scrolling, I have tried to fix it by doing a system restore, downgrading my video drivers and reinstalling photoshop. I also have tried to se

  • BATTERY is messed up

    hey so here is my deal. my battery is totally messed up and i have only had the ipod mini since like mid summer. i'll charge it all night and go to turn it on in the morning and the battery is dead in 5 minutes. howver if i turn it back on a few mins

  • ODI error for Essbase

    Hi John, Was running an interface and came across the following error. AttributeError: class 'com.hyperion.odi.common.ODIConstants' has no attribute 'PRE_LOAD_MAXL_SCRIPT I have not used any MAXl scripts in this.