Finding other files in same ftp to use in applet

I have created a signed applet that can access, write, and delete files within the same folder as the jar file containing the class (signed applets require jar files to hold the class). On my computer I use
String dir = getCodeBase().getPath(); to locate whatever directory the jar file may be in, which works. However, when I put everything (jar, files, signed html applet, etc) on my ftp (same setup as on my computer) and try to run the applet online, it cannot find the files. How do I solve this?

I see... I am not very familiar with client/server interactions. I have made a very simple text messaging before. However, it only allowed one connection a time. Is it possible to create a server that can receive any number of connections to send data needed for the client's applet and receive specific commands to modify certain data on the server side?
In a very basic example:
A server keeps a Serializable file containing a list of names. Any number of client can visit the applet's web page, which automatically makes the connection to the server. The client is then provided with the list of names and the options (JButtons with JTextFields) to add a name, modify a name, or delete a name which changes the file's information.
If such is possible, could you point me to a tutorial that mainly deals about creating this type of server.

Similar Messages

  • Need Help to locate a file on a FTP server using MediaLocator class

    Hi Friends,
    This is Venkat. Iam currently working on a Multimedia J2EE web project. Iam working on a requirement to
    show Thumbnail view for uploaded media. For this i have downloaded a standalone code from the following site.
    http://www.exactfutures.com/index02.htm.
    This code converts frames of a media files to jpg images which i can use them to show as Thumbnails.
    The code takes file name which is present in project folder as parameter. But in my web project iam using a FTP server to store my media files.
    The above code uses Java Media Framework along with another API Fobs4JMF. The media file name is passed to MediaLocator class constructor which is located in the project folder. Iam talking about a standalone application here.
    But my project is a J2EE web application.
    Now my problem is that, how can i refer a file which is located on a external FTP server and pass it to MediaLocator or some other class.
    Say the ftp file URL is mms://wm.testuser.net/12365741/testvideo.wmv
    Guys hope you are clear abt my problem. Please help me ASAP.
    Below is the part of code
         * Constructor
         public vid2jpg(String path) {
              MediaLocator ml;
              String args = path;
              if ((ml = new MediaLocator(args)) == null) {
                   System.out.println("Cannot build media locator from: " + args);
              if (!open(ml)) {
                   System.out.println("Failed to open media source");
         * Given a MediaLocator, create a processor and start
         private boolean open(MediaLocator ml) {
              System.out.println("Create processor for: " + ml);
              try {
                   p = Manager.createProcessor(ml);
              } catch (Exception e) {
                   System.out.println("Failed to create a processor from the given media source: " + e);
                   return false;
              p.addControllerListener(this);
              // Put the Processor into configured state.
              p.configure();
              if (!waitForState(p.Configured)) {
                   System.out.println("Failed to configure the processor.");
                   return false;
              // Get the raw output from the Processor.
              p.setContentDescriptor(new ContentDescriptor(ContentDescriptor.RAW));
    Thanks in Advance for your time.
    Venkat
    Edited by: VenkataGuru on Jul 23, 2008 5:30 PM

    Hi Mani,
    Below is code that ran successfully on a cRIO-9002.  It looks much the same as yours, please double-check the formatting of your string controls.  If things still do not work, let's look at the cRIO more closely.
    Message Edited by Pie56694 on 06-30-2008 09:45 AM
    Attachments:
    FTPDELE3.jpg ‏28 KB
    FTPDELE.jpg ‏24 KB
    FTPDELE2.jpg ‏18 KB

  • How to use a key file in the FTP Task using and SSL connection

    In the past I have used this code to set the FTP pass word in an FTP component task in SSIS.
    Does anyone know how to use a Key file in an SSL connection to download a file from an FTP site?  If not can you tell me where I can get the C# code examples to learn how to create a script task or if there is another way in SSIS to download large files
    from an SSL FTP site?  Thank you for any help offered.
    public void Main()
    ConnectionManager FTPConn;
    FTPConn = Dts.Connections["FTPServer"];
    FTPConn.Properties["ServerPassword"].SetValue(FTPConn, Dts.Variables["FTPPassword"].Value);
    Dts.TaskResult = (int)ScriptResults.Success;
    Antonio

    You can use SFTP for this.
    This is a way of implementing SFTP in SSIS using standard tasks 
    http://visakhm.blogspot.in/2012/12/implementing-dynamic-secure-ftp-process.html
    also see
    http://blog.goanywheremft.com/2011/10/20/sftp-ftps-secure-ftp-transfers/
    Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs

  • Links in Pages document to open other files in same folder

    Hi, In Microsoft Word on my PC I can put links in a Word doc to photos, PDFs and other files that sit in the same folder as the Word doc. Can I do the same in Pages on my Mac, and if so how please?
    I'm using Pages 5.2 in Mavericks.
    Thanks,
    Neil

    Just because you can do these things in MS Word, is no assurance that you can do them in Pages, which is not an MS Word clone.
    Pages v5(.2) only supports links to Web pages and Email.
    Pages ’09 v4+ supports links to another Pages ’09 document, Web page, Email, or internal Bookmark.

  • How to find XSD file? XML to ABAP using XSLT convertor

    Hi Gurus,
    I am trying to convert an XML file to ABAP internal tables using an XSLT transformation. I used the code posted by Durairaj (XSLT program Y_XML_2_ITAB_SIMPLE as mentioned in the link: [Y_XML_2_ITAB_SIMPLE|Parse data to Internal Table;) and the code worked fine.
    My XML file structure is different, and when I try to modify the code for my purposes I got stuck. While changing the XML file strings in the report, I am unable to replace the tag xsi:noNamespaceSchemaLocation="invoice_btm.xsd" correctly. I am also not sure what this file "invoice_btm.xsd" does and where it is stored. When I remove the tag, I get other errors and cannot proceed ahead.
    Can you please advice as to how I should proceed? Also, where can I see the XSD file? can I add a XSD file for my own XML? Or, is there a way to eliminate the need for an XSD file altogether?
    Thanks in advance.
    Regards,
    Shailesh.

    Hi guys,
    Any help would be most helpful. Thanks again,
    Hi guys,
    Any ideas on this issue? Thanks again for your help.
    Hi Naimesh,
    Thanks for the quick reply. I am getting the error "The element abap was expected for the XML-ABAP transformation". I have replaced the following:
    1) "INVOICES_BTM" with the string "ACCOUNT_INFO"
    2) "INVOICE_BTM" with the string "ROOTNODE"
    My XSLT:
    <xsl:transform xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:sap="http://www.sap.com/sapxsl" version="1.0">
      <xsl:template match="ACCOUNT_INFO">
        <asx:abap xmlns:asx="http://www.sap.com/abapxml" version="1.0">
          <asx:values>
            <OUTPUT>
              <xsl:for-each select="ROOTNODE">
                <items>
                  <INV_DATE>
                    <xsl:value-of select="INVOICE_HEAD/INVOICE_DATE"/>
                  </INV_DATE>
                  <INV_NO>
                    <xsl:value-of select="INVOICE_HEAD/INVOICE_NUMBER/NUMBER"/>
                  </INV_NO>
                  <INV_EXT>
                    <xsl:value-of select="INVOICE_HEAD/INVOICE_NUMBER/EXTENSION"/>
                  </INV_EXT>
                  <INV_SEQ>
                    <xsl:value-of select="INVOICE_HEAD/INVOICE_NUMBER/SEQUENCE"/>
                  </INV_SEQ>
                </items>
              </xsl:for-each>
            </OUTPUT>
          </asx:values>
        </asx:abap>
      </xsl:template>
    </xsl:transform>
    My XML program:
    TYPES: BEGIN OF stru,
             inv_date(10),
             inv_no(50),
             inv_ext(10),
             inv_seq(10),
           END OF stru.
    DATA: outtab TYPE STANDARD TABLE OF stru .
    DATA: xslt_error  TYPE REF TO cx_xslt_exception,
          xslt_message  TYPE  string .
    DATA: xml_string TYPE string .
    CLEAR xml_string .
    CONCATENATE
    '<?xml version="1.0" encoding="ISO-8859-1"?>'
    '<ACCOUNT_INFO xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="ROOTNODE.xsd">'
      '<ROOTNODE>'
        '<INVOICE_HEAD LANGUAGE="DE" DIRECT_DEBIT_QUALIFIER="NO">'
          '<INVOICE_DATE>20040112</INVOICE_DATE>'
          '<INVOICE_NUMBER>'
            '<NUMBER>0306299999</NUMBER>'
            '<EXTENSION>1</EXTENSION>'
            '<SEQUENCE>01</SEQUENCE>'
          '</INVOICE_NUMBER>'
    '</INVOICE_HEAD>'
    '</ROOTNODE>'
    '<ROOTNODE>'
        '<INVOICE_HEAD LANGUAGE="DE" DIRECT_DEBIT_QUALIFIER="NO">'
          '<INVOICE_DATE>20040113</INVOICE_DATE>'
          '<INVOICE_NUMBER>'
            '<NUMBER>0306299888</NUMBER>'
            '<EXTENSION>2</EXTENSION>'
            '<SEQUENCE>02</SEQUENCE>'
          '</INVOICE_NUMBER>'
    '</INVOICE_HEAD>'
    '</ROOTNODE>'
    '</ACCOUNT_INFO>'
    INTO xml_string .
    TRY .
        CALL TRANSFORMATION ('ZH2_XML_TRANS_I1')
          SOURCE XML  xml_string
          RESULT     output = outtab.
      CATCH cx_xslt_exception INTO xslt_error.
        xslt_message = xslt_error->get_text( ).
    ENDTRY.
    break-point.
    Edited by: Shailesh S Kamath on Jan 16, 2012 2:17 PM
    Edited by: Shailesh S Kamath on Jan 30, 2012 2:47 PM

  • Finding other files with Centrale

    I have (sadly) upgraded to a new laptop. I have successfully moved all my media files to the new laptop.
    My new laptop has Win7. It is a home deluxe version, and therefore there is no WinXP emulator available. So, my beloved Creative Media Organizer no longer works. I'm stuck with Centrale.
    I download a lot of podcasts and other files that are NOT part of my 'music library' on the laptop, and I cannot, after MANY attempts and much research, figure out how to access files that are not part of the music library with the Creative Centrale (or the Windows Explorer, I tried that too.)
    Any suggestions?

    Do you or have you ever tryed to put dvds on you iPod?
    If they dont rip right they will still go on your iPod and you will have no way to get to them.Have you tryed the following..?
    This bar should not take more than few megabytes so you must have used your iPod in disk mode and added files through My Computer. To delete these go to My Computer > iPod (make sure your iPod "disk use" is enabled in iTunes) and delete the files you added there. DO NOT try to delete any files/folders that you did not create as it will mess up your iPod.
    Best Regards, Zack

  • Create a file at a Windows Vista using java applets

    I have created a java applet which is downloaded to create local file at a Windows Vista PC. The java codes are:
    File out = new File("c:/users/test/hkuesd.properties");
    FileWriter fw = new FileWriter(out);
    PrintWriter pw = new PrintWriter(fw, true);
    pw.println("#sample property file");
    pw.println("key_path=C:/");
    pw.close();
    fw.close();
    If I turn off "Users Account Control" under "Control Panel" --> "User Accounts", the file "hkuesd.properties" is created at c:\users\test and can be found using windows explorer.
    However, if I turn on "Users Account Control", I can not find the file "hkuesd.properties" using windows explorer. But the file can be detected if I run another java applet program with the following codes:
    File xpdir = new File("c:/users/test/hkuesd.properties");
    FileInputStream fis = null;
    if (xpdir.exists()) {
    try {
    fis = new FileInputStream("c:/users/test/hkuesd.properties");
    Properties p = new Properties();
    p.load(fis);
    fis.close();
    privateKeyPath = p.getProperty("key_path", "no value");
    catch (Exception e) {}
    Interestingly, if "Users Account Control" is on and I created the file "c:\users\test\hkuesd.properties" manually, the file creation codes
    mentioned above seems to create another "hkuesd.properties" at the same "c:\users\test". The evidence is I run the second java applet program which can detect the one created by the first java applet but not the one I created manually.

    I agreed that it is hardly explained in words. I
    suggested to write two
    simple java applets using the codes and you will see
    the effects:
    (1) the first applet can create a file
    "hkuesd.properties"
    (2) cannot find the file using windows explorer to
    search the whole drive.
    (3) However, can read the content of the file using
    second applet.You still haven't address your problem of swallowing exceptions. Your code might be throwing an exception that tells you exactly what the problem is. Change your code to display or log that exception.

  • HT5097 How do I find my files after a TC restore using Migration Assistant?

    How do I find my TC backup?
    My difficulties started with my MacBook Pro going totally dead.  Took it to the Apple Store, where they identified a problem with the RAM.  They fixed it, and also reinstalled Lion, but without my applications - Pages, iPhoto, my documents etc. 
    When I got back home, I used Migration Assistant, which I found in Utilities, connected to the Time Capsule with an Ethernet cable, and it said at the end that it had transferred all my info.  During the process I had to create another ID.   I added a "1" to my old id, of course...easiest thing to do....and then I changed the Login procedure so I could switch to that user ID.  I'm not sure that worked, because when my MacBook Pro went to sleep, I found the original icon, rather than the one for the name1 name.  So that may be part of the problem, but I don't know.
    Anyway, then I entered Time Machine, but all that is there is the last few days/hours of activity. 
    I don't know much about computers, but I think that the new name1 user ID and the restored data may be linked somewhere and if I could just find it perhaps this would get resolved.
    I can see the applications now, but when I look for, for example, Pages documents, there is nothing there.  Ditto for iPhoto.  For iPhoto I also tried file>import, which brought in some old files from MobileMe, but not the photos I had on my MacBook. 
    I would prefer not to have the name/name1 and just have everything back as it was, but I don't know how to do that either.
    Hope someone can help me!  Many thanks!!!

    Never mind!  I finally figured out - duh - that if I logged out and then logged in under the new name1 ID, I could find everything!  HOOORAY!

  • My Itunes Shows The downloads history...but when I try to play them it states it can not find the file.  (same computer for the last 2 years) and no issues. now 1/2 of my library can not be played (as it can not be found)

    When I try and re-download some of them from the ITUNES store...I get an error that the file already exists on the computer.  However, when I open Itunes.  The file can not be found.  This problem just started about 1 1/2 ago...prior to that did not have any problems...Help?  direction?

    You can move the folder to where iTunes expects to find it and that will work.
    Or you can attempt to fix one broken track by looking for it when prompted when you use Get Info or attempt to play. This often works if everything is in the standard layout.
    Or you can repair things with my FindTracks script.
    tt2

  • Getting the file from IIS FTP Server using ALSB

    Hi,
    I want to extract a file from FTP server in ALSB.I am using ALSB2.5 and Microsoft IIS FTP Server.
    Now i want to know that
    1.Do i need to configure a Proxy service or Business Service to poll a file from FTP server?
    2.How to read the contents of the file once the File comes in?
    Regards,
    Indu Garg

    You need to configure a Proxy service for the polling.
    The contents of the file will be inside the context variable $body.

  • JW player won't play files on a page on a site but will play other files on same site

    i am a frequent visitor to a website call www.tvpmmvault.com, some of the pages have audio flies that use jwplayer, on one of the pages the files won't play in the player giving me an error message that says the file can not be played the funny the thing is that other pages that use jwplayer work just fine and the same page works ok on chrome
    can you tell me what is wrong

    Yes, there are a number of issues that could have occurred: [http://support.jwplayer.com/customer/portal/articles/1403682-troubleshooting-your-setup]
    What was the media format of the file on that site? The url to the file can be seen in the "Show Page Source" options when you right click on the webpage.
    It could be the media type, however you can also check to make sure your plugins are up to date:This article will show you where the plugin check page is: [[Flash Plugin - Keep it up to date and troubleshoot problems]]

  • After setting up Time Machine can't find other files on TC!

    I first used TC as a disk to back up some files, then configured it as Time Machine. Now I can't find the original files anymore. Have the files been wiped out? Does Time Machine set-up partition the disk?
    Thanks

    Homestone wrote:
    Thank you for the detailed instructions on your Time Machine site!
    I wonder if it all still applies to OSX 10.6.8, latest Airport Utility and Time Capsule 2TB (purchased 5 days ago) ...
    Yes.
    You say Time Machine sparsebundle expands over time, possibly overwriting other data on the disk.
    No.  It won't delete anything else, but it will, eventually,  fill all the space available to it.
    you give instructions on how to expand the sparsebundle with Disk Utility.
    No, the instructions are to limit the maximum size of the sparse bundle.
    Is sparsebundle a disk image or a partition?
    A rather odd type of disk image.
    If keeping other data on TC disk would be risky, why is file sharing an option in Airport Utility, even over WAN, Mobile Me, Bonjour?
    Because you can do either.  Apple allows you to do both, which is ok in some situations, but usually it becomes a problem, sooner or later.
    Perhaps Apple has solved those problems with new hardware/software?
    No.  You still can't partition the TC's internal HD, short of physically removing it, which voids the warranty.  Thus the workarounds.

  • Compiler cannot find other files

    Ok, whenever I try to compile any file the references another file I've written it tells me that it "cannot find symbol". Everything is correct as I can compile just fine on other computers that have java installed on them, but this one seems to hate it for some reason. I have a windows xp machine with an intel processor, and I have the latest version of java 1.5.0_06. Anyone have any ideas what could be causing this to happen? Thanks for your help.

    Here is the compile error
    "CampStore.java:5: cannot find symbol
    symbol : class CampStoreGUI
    location: class CampStore
    CampStoreGUI gui = new CampStoreGUI(); "
    CampStore and CampStoreGUI are in the same file, and CampStoreGUI class is compiled and as stated before, the entire program compiles on other PCs. The path name to javac.exe is C:\Program Files\Java\jdk1.5.0_06\bin. This may be helpful:
    "C:\Documents and Settings\Bryn Robbins\My Documents\Brent\Java\campStore>javac CampStore.java -verbose
    [parsing started CampStore.java]
    [parsing completed 50ms]
    [search path for source files: []]
    [search path for class files: [C:\Program Files\Java\jdk1.5.0_06\jre\lib\rt.jar,
    C:\Program Files\Java\jdk1.5.0_06\jre\lib\jsse.jar, C:\Program Files\Java\jdk1.
    5.0_06\jre\lib\jce.jar, C:\Program Files\Java\jdk1.5.0_06\jre\lib\charsets.jar,
    C:\Program Files\Java\jdk1.5.0_06\jre\lib\ext\dnsns.jar, C:\Program Files\Java\j
    dk1.5.0_06\jre\lib\ext\localedata.jar, C:\Program Files\Java\jdk1.5.0_06\jre\lib
    \ext\sunjce_provider.jar, C:\Program Files\Java\jdk1.5.0_06\jre\lib\ext\sunpkcs1
    1.jar]]
    [loading C:\Program Files\Java\jdk1.5.0_06\jre\lib\rt.jar(java/lang/Object.class
    [loading C:\Program Files\Java\jdk1.5.0_06\jre\lib\rt.jar(java/lang/String.class
    [checking CampStore]
    CampStore.java:5: cannot find symbol
    symbol : class CampStoreGUI
    location: class CampStore
    CampStoreGUI gui = new CampStoreGUI();
    ^
    CampStore.java:5: cannot find symbol
    symbol : class CampStoreGUI
    location: class CampStore
    CampStoreGUI gui = new CampStoreGUI();
    ^
    [total 340ms]
    2 errors".

  • HT204135 Printing email to PDF it will overwrite if other file with same name

    When printing an email to PDF (in OS X 10.8.2) it will overwrite if another already printet with the same name, this did not happen in older versions. Why?

    Hi,
    When you create a snapshot you create a snapshot task which (provided you are using a server-side data store) can be run from a job. To refresh the data, run the snapshot task as part of a job. If you create a job with both the snapshot and the process that uses it, they will automatically connect and will 'stream' the data through the snapshot into the process. You can then choose whether actually to write the snapshot or not (for improved performance efficiency if you want to do straight-through processing) by either enabling or disabling the staged data bucket that the snapshot writes to. The snapshot task being in the job means the data will be refreshed.
    For design work in Director, you can refresh the snapshot by re-running it manually from the right-click menu.
    Regards,
    Mike

  • Hi. How I can find other files and remove them?

    I have 42 GB of other storage, how can I delete it? I dont believe that osx is 40 GB large. Waiting for some advice, searched the web, but there is nothing really helpful.

    "Other" is the category when a file is not one of the other categories (Audio, Movies, Photos, Apps or Backups).  So these are files like documents (probably stored in the "Documents" folder for your user).
    You are not really short on disk space... so is there a problem?

Maybe you are looking for

  • Unplanned delivery cost for different Vendor

    Hi,    For a import PO we need to pay OCTOI to Municipal corporation. Unfortunately while PO creation the octroi condition was not entered. Now we need to post a invoice for this and the condition is, we must post this to material. We dont want to do

  • Error when launching Flex Builder 3

    Hello, I'm new to flex and just downloaded the trial version of Flex Builder 3. When launching the builder, I get the following error in the log. What am I missing? !SESSION 2008-12-07 21:08:26.880 eclipse.buildId=unknown java.version=1.5.0_11 java.v

  • Creating 1 pdf file from 2 or more pdf files

    Is it possible to combine two or more pdf files into one pdf file ?

  • Classic-160 Continues To Crash

    My iPod Classic-160 is the third one in my possession; the other two have been brought back to Apple and replaced-cheerfully. All have misbehaved in the same, exact way; they crash when a command is implemented in conjunction with a large playlist (i

  • Safari 6.0.1 typing glitch in Mac OS 10.8.2 (Video)

    When typing cetrain words in applications the cursor moves BEHIND the word I typed instead of in front of it. Any suggestions to this, please tell. Video of the problem is attached http://www.youtube.com/watch?v=RBUdKlNb5vc