How to 'deploy' an Applet when class files are on client machine?

Hi all,
I've searched through these forums and I can't find where my specific question has been asked before, so please accept my apologies for any duplication.
I am trying to develop an applet for use on an intranet. (The specific requirement is that the applet must operate a scanner, and upload the scanned images to the database - we want it to be an applet so that it seamlessly integrates with the rest of the web application from the user's POV).
Therefore the applet needs to run outside of the sandbox, but I don't want to go to all the hassle of getting a certificate from Verisign and signing the applet - that doesn't seem like it should be necessary, since there is no problem getting access to the client PC to install the class files by hand!
I have read on this tutorial page that applets "that are loaded from the local file system (from a directory in the user's CLASSPATH) have none of the restrictions that applets loaded over the network do," so I don't think I am barking up the wrong tree:
http://java.sun.com/docs/books/tutorial/deployment/applet/security.html
That is exactly what I want to do! But whenever I try to run the applet, I get a no class definition found exception. However, if I run the applet as a standalone application (using its static main method) then the JRE has no trouble locating the class file - so I know that my CLASSPATH environment variable is set ok.
Therefore I think the problem must be in my JNLP file. This is what mine looks like at present:
<?xml version="1.0" encoding="UTF-8"?>
<jnlp spec="1.0+" codebase="http://localhost:8080/JGNS008" href="http://localhost:8080/JGNS008/scanner-applet.jnlp">
    <information>
        <title>Scanner Applet Prototype</title>
        <vendor>Fooware</vendor>
    </information>
    <resources>
        <!-- Application Resources -->
        <j2se version="1.6+" href="http://java.sun.com/products/autodl/j2se" />
        <jar href="ScannerApplet.jar" main="false" />
    </resources>
    <applet-desc
         name="Scanner Applet Prototype"
         main-class="uk.co.fooware.ScannerApplet"
         width="72"
         height="20">
     </applet-desc>
     <update check="background"/>
</jnlp>How do I rewrite this so that it doesn't try to download the class files from the network?
Many thanks,
Richard.

richardwild wrote:
..I am trying to develop an applet for use on an intranet. (The specific requirement is that the applet must operate a scanner, and upload the scanned images to the database - we want it to be an applet so that it seamlessly integrates with the rest of the web application from the user's POV).
Therefore the applet needs to run outside of the sandbox, but I don't want to go to all the hassle of getting a certificate from Verisign and signing the applet - that doesn't seem like it should be necessary,.. Code can be digitally signed without a 'verified' certificate from Versign.
..since there is no problem getting access to the client PC to install the class files by hand!
I have read on this tutorial page that applets "that are loaded from the local file system (from a directory in the user's CLASSPATH) have none of the restrictions that applets loaded over the network do," so I don't think I am barking up the wrong tree:
http://java.sun.com/docs/books/tutorial/deployment/applet/security.html
Huh. I had never heard of that, but since I do not have access to my end user's classpath it is not that important to me.
BTW - I am guessing they mean the path indicated by [http://pscode.org/prop/all.html?prop=java.class.path].
And putting classes into JRE folders seems very hackish to me.
That is exactly what I want to do! But whenever I try to run the applet, I get a no class definition found exception. However, if I run the applet as a standalone application (using its static main method) then the JRE has no trouble locating the class file - so I know that my CLASSPATH environment variable is set ok.Huh?
Therefore I think the problem must be in my JNLP file. Huh?!? Why not deploy the applet using a standard applet element? The only way to configure an applet using a JNLP is ..
a) If the applet is intended to be free floating.
b) If the applet is intended to be embedded in a plug-in2 architecture JRE. Why impose that restriction, when it seems unnecessary and unproductive?
Note that the second option is very new, and I would not expect all the things mentioned in the document you linked, to apply equally to JNLP embedded applets. If you want this applet embedded, I suggest you drop the entire JNLP approach and use a standard applet element.

Similar Messages

  • URGENT PLEASE:How can I run a a class file on the Apache server?

    Hi Guys and Gurus,
    I am seeking some favor all of experienced gurus, i.e.
    How can I run a a class file on the Apache server? Can I run through an Applet?
    How can I set Environment variables in Windows2000 Professional Environment?
    Actually, I want to extract some records from a MySQL Database running on Apache Server. I wrote a program just to select the columns and show them. It is now a Class file, Now how can I run this class file from the Server???
    The code is here
    import java.sql.*;
    public class RecordShow {
    public static void main(String args[]) {
    String url = "jdbc:mysql://localhost/myhost";
    Connection con;
    String query = "select mytable.column," +
    "from mytable " +
    "where mytable.column = 1";
    Statement stmt;
    try {
    Class.forName("com.mysql.jdbc.Driver");
    } catch(java.lang.ClassNotFoundException e) {
    System.err.print("ClassNotFoundException: ");
    System.err.println(e.getMessage());
    try {
    con = DriverManager.getConnection(url,
    "myuser", "mypassword");
    stmt = con.createStatement();
    ResultSet rs = stmt.executeQuery(query);
    ResultSetMetaData rsmd = rs.getMetaData();
    int numberOfColumns = rsmd.getColumnCount();
    int rowCount = 1;
    while (rs.next()) {
    System.out.println("Row " + rowCount + ": ");
    for (int i = 1; i <= numberOfColumns; i++) {
    System.out.print(" Column " + i + ": ");
    System.out.println(rs.getString(i));
    System.out.println("");
    rowCount++;
    stmt.close();
    con.close();
    } catch(SQLException ex) {
    System.err.print("SQLException: ");
    System.err.println(ex.getMessage());
    Please advise... THANKS
    VJ

    Ehm, I wasn't referring to you at all... read up,
    there's a comment by jschell saying that CGI might be
    easier/better for his purposes.
    Yep.
    I know PHP/Perl/whatever might be easier for some
    purposes, but only if you happen to know them and want
    to/are able to use them. Ok. But you aren't the one asking the question are you. And the person who asked the question seems to have absolutely no familiarity with Apache or applets.
    So whatever they do they are going to have to learn a lot.
    And that does indeed suggest that in all likelyhood they have not investigated the alternatives.
    And for the vast majority of internet applications, especially with smaller projects (obvious this person is not working with a large team), using perl, or something besides java, is going to be the best business solution. It is simpler, and more secure (probably due to the fact that it is simpler.)
    Since this is a Java forum, I
    answer under the assumption that people have made a
    choice one way or another to use a Java solution to
    their problem, so I try to solve it in Java first, and
    only when that fails (very seldom) do I turn to other
    solutions.You approach problems by arbritrarily deciding to try to solve it in java first and only if you fail do you then look to other solutions?
    My first step is to try to figure out which of the various avenues is going to cost less. (And a secondary, but non-trivial concern, is then to convince the customer that just because they have heard of a buzz word like 'enterprise bean' that it doesn't mean that is a cost effective solution.) We must come from different worlds.

  • How to deploy custom jar (forms PJC)  file in R12.1.x

    Hi ,
    we need use forms pjc connecting to client pc'com port with ebs form,
    we can deploy with ias standard form server , but EBS 's appsweb.cfg
    was automatically generated by AutoConfig , so i don't know how to config our jar in EBS env.
    i had search document in metalink for serval days , can some help us to solve this problem !
    thanks for any help...
    BR,Nolem

    Hi all, I am confronted by the same problem.
    I have manually added my custom Jar files to the archive=2 section of the appsweb.cfg config file in the $INST_TOP/ora/10.1.2/forms/server and placed the Jar files in the $COMMON_TOP/java/classes/oracle/apps/fnd/jar.
    I know that this is probably not the way to go, as autoconfig will override these settings, but my first priority is getting these jar files to run in Apps Forms without errors. I got as far as that my forms don't error out anymore but not all of them are working as they should. I am also trying to deploy the WebUitl utility in EBS R12. As far as I can tell this should be supported by Oracle as it comes as part of a standard Apps Installation (except for the Jacob.jar) it can be found in: $ORACLE_HOME/forms/webutil directory and the WEBUTIL_CONFIG reference to the webutil.cfg file can be found in the default.env in the same directory as the appsweb.cfg.
    If you want to look at some very good examples of PJC's there is a very good blog: http://forms.pjc.bean.over-blog.com/. You can also look at Francois Degrelle's blog on Read/Write files on the client machine without Webutil.
    Nevertheless information on how to deploy and run these PJC's under EBS is scarce. Metalink offers no solutions except very outdated notes.
    I would appreciate to know how to properly deploy these jar files in EBS
    I am also on 12.1.x. Btw there are more threads on this subject on OTN but most are outdated (threadID=1067917, 686329, 4246525) and don't provide the solution for EBS R12.1.x.
    Any help would be appreciated.

  • How to reference a set of Flash-protected f4v files in a manifest when the files are on Cloudfront?

    I have: a self-created AMS 5.0 running on Amazon.
    Using latest OSMF player.
    I'm Using EZDRM for Flash Access protection.
    I have a dynamic bitrate f4m created with the F4F packager. It contains data for three bitrates.
    I know that my S3 bucket and Cloudfront distribution are generally working because I can play a set of non-drm files using a RTMP-style manifest
    I am successfully  issuing the license and playing the videos using that manifest when the files are located on the AMS itself.
    The working call to the manifest is this: http://media.blah.com/vod/BlahBlah/Blah.f4m
    I think the relevant portion of the manifest is this:
                      streamId="Blah-1000" 
    url="Blah-1000"
    bitrate="1000"
    bootstrapInfoId="bootstrap4543"
    drmAdditionalHeaderId="drmMetadata8495"
    I think the correct way to approach this it to leave the manifest on AMS and manually change the url in the manifest for each video file
    I've tried changing the url in the manifest to point to the cloudfront location
    http://blahblah.cloudfront.net/cfx/st/mp4:Blah
    But I simply get back: "We are unable to connect to the content you requested."
    Your guidance greatly appreciated.
    Ken Florian

    Hi,
    I created a project (JDeveloper) with local xsd-files and tried to delete and recreate them in the structure pane with references to a version on the application server. After reopening the project I deployed it successfully to the bpel server. The process is working fine, but in the structure pane there is no information about any of the xsds anymore and the payload in the variables there is an exception (problem building schema).
    How does bpel know where to look for the xsd-files and how does the mapping still work?
    This cannot be the way to do it correctly. Do I have a chance to rework an existing project or do I have to rebuild it from scratch in order to have all the references right?
    Thanks for any clue.
    Bette

  • How do I copy my old xl files from my XP machine to operate on xl for Mac on my new iMac.  When I copy them onto a stick and transfer them it automatically makes them xls files which are then corrupted when I try to open them in xl for mac

    How do I copy my old xl files from my XP machine to operate on xl for Mac on my new iMac.  When I copy them onto a stick and transfer them it automatically makes them xls files which are then corrupted when I try to open them in xl for mac

    Sorry, yes this is Microsoft Excel.  The Microsoft XP has Excel files denoted as xl, the later versions of Microsoft Excel are denoted as xls files.  The later verions of Microsoft Excel open the xl files OK, does Excel for Mac not able to do this?

  • How can I run a a class file on the Apache server?

    Hi Guys and Gurus,
    I am seeking some favor all of experienced gurus, i.e.
    How can I run a a class file on the Apache server?
    Actually, I want to extract some records from a MySQL Database running on Apache Server. I wrote a program just to select the columns and show them. It is now a Class file, Now how can I run this class file from the Server???
    Please advise...
    VJ

    cross posted
    http://forum.java.sun.com/thread.jsp?thread=299137&forum=31&message=1184025

  • How do I set up InDesign cross-document Text Anchor Hyperlinks so that when the files are moved, they remain active?

    I’m combining several InDesign files into one PDF, with several hundred text links across the different sections, as well as within each. The cross-document (section) Text Anchor Hyperlinks work fine in my workspace - but when I change the file location, they are no longer active (other links, bookmarks remain intact).
    How do I set up InDesign cross-document Text Anchor Hyperlinks so that when the files are moved, they remain active? 

    They seem to be a lot of extra work, and I don't see what the additional benefit is. I have several hundred links to do. I would appreciate learning what the benefit is, as I don't mind the extra effort if it will deliver the desired results.

  • How to deploy a project to EAR file

    Hi,
    I am a new bee to Jdeveloper. Could some body give me hints how to deploy my project to EAR file as I need to handover that EAR file to my admin to deploy it on the Application server.
    I am following these steps
    right clicked on the project >> click NEW >> Deployment profiles >> select EAR file from the right hand side and click OK >> given the deployment profile name as Jobmanage
    And selected the path as C:\Oracle_Jdeveloper\jdev\mywork\MANAGEJOB\Project and clicked OK >> and given the application name as Jobmanage and pressed OK>>
    In the Deploy folder of the project the EAR project is created but it is only 7 KB which is normally above 4 MB.
    And it automatically creatig a file underneath RESOURCES >> Jobmanage.Deploy
    Cheers,
    Krishna

    More specifically,
    - create a WAR deployment profile (New... -> General -> Deployment Profiles -> WAR File)
    - create an EAR deployment profile (New... -> General -> Deployment Profiles -> EAR File)
    - double-click on the EAR deployment profile and tick the check box for the WAR deployment profile.
    --olaf                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • How to disable itunes store when transferring files to ipod shuffle

    Hi,
    I just started using my ipod shuffle a few days ago, using itunes on mac OS 10.4. To try it out, I used a handful of podcasts downloaded from the itunes store.
    My problem is that whenever I try to move a file from my computer to my ipod shuffle, itunes seems to want to open up the itunes store (as declared by itunes in the top oval window) instead of showing the list of files on my shuffle. However, I've already disabled the itunes store through parental controls. My internet at home is rather slow at the moment, and it's annoying to have to close the blank "store" window each time I load something onto my ipod shuffle. Is there a way to disable the itunes store, specifically when I'm moving files to my ipod shuffle (in addition to using the parental controls)?

    Provided the files were properly tagged then iTunes should pick up the data when the files are imported into the library. The main problem is usually any files in .wav format.
    See also Recover your iTunes library from your iPod or iOS device. You seem to be most of the way there already but there are a couple of scripts mentioned near the end which you could use to recover ratings & playlists.
    tt2

  • How to refresh XML file  from my client machine

    Hai All
    I have temp.XML and temp.XSL template in our server machine.
    when i give a print from client machine first time it gives the record,and next time it did not get refresh.Always it shows the previous records in the browser.But when i go into the server machine and click on temp.xml,it shows the current record(correct records)
    How to refresh XML file  from my client machine?
    Regards
    Dhina

    You never delete a Time Machine backup by dragging it to the Trash. You are supposed to use the TM application to manage the backups. What you will need to do now is to simply erase the drive using Disk Utility.

  • File corruption on SDCard when multiple files are being written from WinCE 6.0R3

    We currently have file corruption problems which we have been able to reproduce on our system which uses WinCE 6.0R3. We have an SDCard in our system which is mounted as the root FS.  When multiple files are being written to the file system we occasionally
    see file corruption with data destined from one file, ending up in another file, or in another location in the same file.  We have already written test SW that we have been able to use to reproduce the problem, and have worked with the SDCard vendor to
    check that the memory controller on the card is not the source of the problems.
    We know that the data we send to WriteFile() is correct, and that the data which eventually gets sent through the SDCard driver to the SD card is already corrupted.
    We believe that the problem is somewhere in the microsoft private sources between the high level filesystem API calls and the low level device calls that get the data onto the HW.
    We have confirmed that the cards that get corrupted are all good and this is not a case ofpoor quality flash memory in the cards. The same cards that fail under WinCE 6.0R3 never fail under the same types of testing on Windows, Mac OX, or linux.  We
    can hammer the cards with single files writes over and over, but as soon as multiple threads are writing multiple files it is only a matter of time before a corruption occurs.
    One of the big problems is that we are using the sqlcompact DB for storing some data and this DB uses a cache which get's flushed on it's own schedule. Often the DB gets corrupted because other files are being written when the DB decides to flush.
    So we can reproduce the error (with enough time), and we know that data into the windows CE stack of code is good, but it comes out to the SDcard driver corrupted.  We have tried to minimize writes to the file system, but so far we have not found a
    way to make sure only one file can be written at once. Is there a setting or an API call that we can make to force the OS into only allowing one file write at a time, or a way of seeing how the multiple files are managed in the private sources?
    Thanks
    Peter

    All QFE's have been applied we are building the image so we have some control.
    I have build an image which used the debug DLL's of the FATFS and I have enabled all of the DebugZones.  The problem is still happening. From the timings in the debug logs and the timestamps in the data which corrupts the test file I have been able
    to see that the file is corrupted AFTER the write is complete. Or at least that's how it seems.
    We finished writing the file and closed the handle. Then more data is written to other files. When we get around to verifying the file it now contains data from the files that were subsequently written.
    What I think I need to do is figure out in detail how the two files were "laid down" onto the SDCard.  If the system used the same cluster to write the 2 files then that would explain the issue.

  • Developer class files are downloaded every time

    The jinit jar files are being cached. However the developer class files are being downloaded everytime. I’ve written other web aps where classes were downloaded only once - there is a way for classes to only download once and then automatically download when changed / added – similar to jinitiator – that is critical – just can’t expect a user to repetitively wait a few minutes to use an ap.
    Installed versions are:
    Java 2 Runtime SE v1.4.1_07
    Java 2 SDK, SE v1.4.1_05
    Microsoft IE 6 SP1
    Oracle JInitiator 1.3.1.17
    Microsoft Windows 2000 [Version 5.00.2195]
    Oracle8i Enterprise Edition Release 8.1.7.0.0 - Production
    Forms server 6i patch 16
    Web server 9iAS rel 1

    George,
    Forms files (jar) are cached and only checked for its timestamp. There are a few classes that are accessed directly and I don't know why - I think one of the EWT classes if i remember well. So 99.99 % of all files are cached.
    Frank

  • I have a 27" iMac with 16GB of factory installed SDRAM and 1T harddrive.  It is telling me the harddrive is full and is not functioning correctly.  How can I adjust so that all files are managed on the harddrive rather than the SDRAM.  (BTW - design flaw)

    Processor 3.4 GHz Intel Core i7
    Memory  16 GB 1333 MHz DDR3
    I have a 27" iMac with 16GB of factory installed SDRAM and 1T harddrive.  It is telling me the harddrive is full and is not functioning correctly.  How can I adjust so that all files are managed on the harddrive rather than the SDRAM.  (BTW - design flaw here.)
    Older Macs with a single Harddrive would simply expand OS management on the drive, and I think I understand the new Fusion Drive to do just that, but how do I get this product that I spent a great deal of money on to be more than a pretty screen?

    I was confused by this statement
    It is telling me the harddrive is full and is not functioning correctly.
    OS X manages ram and when you run out, it create swapfiles to extend your ram on the HDD (Hard Disk Drive). The OS itself, takes about 16 gig of space and that too resides on the HDD.  Your 16 gig of RAM is really a temporary space that holds things from the HDD so the processor can work on them.  There is no design flaw between your ram and HDD.  Something else is going on and there are a lot of smart people here to help you figure out what that "something else" is.
    I would do three things.  First I would create a backup, backups are important.  Second, I would reboot into recovery and repair my HDD.  Lastly while still booted in recovery I would repair permissions.
    Can you capture a screen shot of the exact error you are getting?

  • I have a new computer and my old drive has my UNSAVED bookmarks on it and I want to import them, how do I do it when the bookmarks are not SAVED?

    I have a new computer and my old drive has my UNSAVED bookmarks on it and I want to import them, how do I do it when the bookmarks are not SAVED?

    You can backup the bookmarks on the old computer and create a JSON or HTML backup and restore or import this file in the Bookmarks Manager (Bookmarks > Show All Bookmarks).
    You can use an USB stick to transfer the saved bookmarks file to the new computer.<br />
    You can also copy the places.sqlite file from that computer to have the bookmarks and the history.
    *http://kb.mozillazine.org/Transferring_data_to_a_new_profile_-_Firefox
    *http://kb.mozillazine.org/Backing_up_and_restoring_bookmarks_-_Firefox

  • How to upload file from a client machine to server machine

    hei evryone!
    can anyone pls help me on how i can upload file from a client machine to another machine (or server). using jsp.Then later on, i can also retrieve the names of these files to place it as values for option tag in an html form.I have a seperate screen for uploading the file and the screen for displaying all the files that were uploaded on the server...
    any sample code/ ideas would be much appreciated.Thx!!!!

    hei evryone!
    can anyone pls help me on how i can upload file from a client machine to another machine (or server). using jsp.Then later on, i can also retrieve the names of these files to place it as values for option tag in an html form.I have a seperate screen for uploading the file and the screen for displaying all the files that were uploaded on the server...
    any sample code/ ideas would be much appreciated.Thx!!!!

Maybe you are looking for

  • ITunes has corrupted my iPod Classic's data

    I recently upgraded to a new computer, now running Windows 7 from XP and also with that installed the latest version of iTunes. I had never had too much trouble prior syncing and managing my music until recently when all of a sudden syncing even smal

  • My iPad 1 headphone jack don't work anymore.HELP!!!

    My IPad headphone jack don't work anymore. I have tested it with three headphones.Sorry I'm german and my englisch isn't the best.

  • After editing raw in external editor, where does Aperture store that image?

    When I have Aperture send a raw file over to Photoshop for more editing, Aperture creates a PSD (or TIFF) and saves it to its internal library. So, since my raw images are imported into Aperture as referenced files (I want to maintain my image librar

  • How to increase the charecteristic description length Copa report

    Hi All I built a copa report with material and customer as characteristics for a drill down report. Unfortunately, the total description of the material is not showing up in the report. Is there any way that we can increase the description field leng

  • OBA - Attention: configuration error

    Hi All, recetly we completed the OBA [R12.1.3] Installation. After this installation, we ran the Configuration tool, the setup stopped at 5%. and It thows an error as fallows: Attention: configuration error Action : Close all browser windows before r