Strange applet situation

I have an applet (code below) that was compiled like so:
javac -target 1.1 DigiClock.java
that class is then used in the applet tag.
My machine has the 1.3 plugin, but no others do. I am the only one that can see the applet. Everyone else gets a grey box with no errors.
None of the code, as far as I can tell is beyond 1.1.
Any thoughts?
import java.awt.Graphics;
  import java.awt.*;
  import java.util.*;
  import java.text.*;
  public class DigiClock extends java.applet.Applet
         implements Runnable
     Font theFont = new Font("TimesRoman", Font.BOLD, 16);
     Date theDate;
     Thread runner;
     private SimpleDateFormat formatter;
     int h, m;
     String bi, tz;
     public Image bg;
      public void start()
          bi = getParameter("bgimage");
          bg = getImage(getCodeBase(), bi);
          tz = getParameter("timezone");
          System.out.println(tz);
          formatter = new SimpleDateFormat ("EEE MMM dd hh:mm:ss yyyy", Locale.getDefault());
          try {
               formatter.setTimeZone(TimeZone.getTimeZone(tz));
          catch(NullPointerException e) {
               formatter.setTimeZone(TimeZone.getTimeZone("Europe/Germany"));
          // start thread
       if (runner == null )
              runner = new Thread(this);
              runner.start();
        } // end of start
      public void stop()
       if (runner != null )
              runner.stop();
              runner = null;
        } // end of stop
       public void run()
           while(true)
               repaint();
               try { Thread.sleep(1000); }
               catch (InterruptedException e) { }
          } // end of run
     public void paint(Graphics g)
            theDate = new Date();
            formatter.applyPattern("h");
            formatter.format(theDate);
            h = Integer.parseInt(formatter.format(theDate));
         formatter.applyPattern("m");
         m = Integer.parseInt(formatter.format(theDate));
         g.drawImage(bg, 0,0,this);
            g.setFont(theFont);
            g.setColor(Color.white);
            g.drawString(h + ":" + m, 95,18);
            theDate = null;
          } // end of paint
      } // end of class

Are 'others' running it from a webserver somewhere or off local filesystem? If running from local filesystem you will get an AccessControlException when reading the image.

Similar Messages

  • A strange applet selection fail problem

    Hi, All. I am trying to implement the RSA encryption and decryption using rmi. I use the RSA implementation sample code in the previous post and the RMIPurse sample code in the package (3.0.2 classic ) for testing. However, after I add some initialization codes into the PurseImpl class, I got the "applet selection failed" error.
    The code that I modified based on RMIPurse
    import javacard.framework.ISO7816;
    import javacard.framework.ISOException;
    import javacard.security.CryptoException;
    import javacard.security.KeyBuilder;
    import javacard.security.KeyPair;
    import javacard.security.RSAPrivateCrtKey;
    import javacard.security.RSAPublicKey;
    import javacardx.crypto.Cipher;
    public class PurseImpl extends CardRemoteObject implements Purse {
        private short balance = 0;
        private byte[] number;
         // crypto variables
         final static byte GETSET_CLA = (byte) 0x85;
         final static byte CRYPT_CLA = (byte) 0x00;
         // Instruction set for SimpleString
         final static byte SET = (byte) 0x10;
         final static byte GET = (byte) 0x20;
         final static byte SELECT = (byte) 0xA4;
         // This buffer contains the string data on the card
         byte TheBuffer[];
         // globals
         RSAPrivateCrtKey rsa_PrivateCrtKey;
         RSAPublicKey rsa_PublicKey;
         KeyPair rsa_KeyPair;
         Cipher cipherRSA;
         final short dataOffset = (short) ISO7816.OFFSET_CDATA;
        public PurseImpl() {
            super(); // export it
            number = new byte[5];
              // crypto
            TheBuffer = new byte[100];
            // generate own rsa_keypair
            try {
                   rsa_KeyPair = new KeyPair(KeyPair.ALG_RSA_CRT, KeyBuilder.LENGTH_RSA_1024);
                   rsa_KeyPair.genKeyPair();
                   rsa_PublicKey = (RSAPublicKey) rsa_KeyPair.getPublic();
                   rsa_PrivateCrtKey = (RSAPrivateCrtKey) rsa_KeyPair.getPrivate();
                   cipherRSA = Cipher.getInstance(Cipher.ALG_RSA_PKCS1, false);
              catch (CryptoException e) {
                short sw = (short) 0x9100;
                sw |= e.getReason();
                ISOException.throwIt(sw);
        }I got:
    Receiving initial reference... java.rmi.RemoteException: Applet selection failed, SW = 6d00
    That's strange. because without the initialization codes in try/catch block, there is no problem to select the applet. Can anyone help?

    I have exactly the same problem when calling (trying to) any applets method. Where are these parameters to be turned on?

  • Strange Facetime situation

    Hello everyone.
    So my gf bought her factory unlocked iphone 4, and we have been trying out facetime quite alot lately. And we noticed a strange situation and it seems very consistent.
    Whenever I call her FaceTime from my MBP Pro (Beta version of facetime), I ALWAYS have to call her twice to get the video thru. The first time I called, we can only get voice, and I have to immediately hang up and call back to get the video part. Vice and versa.
    Does any of you have this problem?
    What gives?
    Thanks
    iphone 4, iOS 4.3.3

    I'm not, but the FaceTime beta for the Mac is obsolete. Why beat your head against the wall troubleshooting it when it may be fixed in the current version?

  • Strange Applet Behaviour

    I've created an Applet as a search tool for my website. When I run it from within the development system (CodeWarrior v8) it runs fine. When I do a drag and drop of the html file from the development area into the browser, it works fine. I've uploaded it to me website and the applet fails. Any help would be appreciated.
    http://members.fortunecity.com/mermaids_tail/index2.htm

    As I indicated, I think you may need to run your applet tag through the tag converter. Only older 1.1 applets work with a plain applet tag. Newer versions of Java require an advanced tag to fire up the runtime environment.
    Compare the difference (note that I have used a 1.3 tag ...there are even newer versions for 1.3.1 ...1.4 etc, etc):
    Your tag:
    <APPLET CODEBASE = "." ARCHIVE = "MertailApplet.jar"
    CODE = "MertailApplet.MertailApplet.class" NAME = "MertailApplet"
    HSPACE = "0" VSPACE = "0" ALIGN = "middle"
    WIDTH = "800" HEIGHT = "600">
    </APPLET>Your tag converted to use 1.3 Java...
      <!--"CONVERTED_APPLET"-->
    <!-- CONVERTER VERSION 1.3 -->
    <OBJECT classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93" WIDTH = 800 HEIGHT = 600
       ALT = "Your browser understands the applet tag but isn\'t displaying any applet."
       codebase = "http://java.sun.com/products/plugin/1.3/jinstall-13-win32.cab#Version=1,3,0,0">
      <PARAM NAME = CODE VALUE = "MertailApplet.MertailApplet" >
      <PARAM NAME = CODEBASE VALUE = "." >
      <PARAM NAME = ARCHIVE VALUE = "MertailApplet.jar" >
      <PARAM NAME = MAYSCRIPT VALUE = "false" >
      <PARAM NAME = "type" VALUE="application/x-java-applet;version=1.3">
      <COMMENT>
      <EMBED type="application/x-java-applet;version=1.3"
       CODE = "MertailApplet.MertailApplet" CODEBASE = "." ARCHIVE = "MertailApplet.jar"
       ALT = "Your browser understands the applet tag but isn\'t displaying any applet."
       WIDTH = 800 HEIGHT = 600 MAYSCRIPT=false
       scriptable=true pluginspage="http://java.sun.com/products/plugin/1.3/plugin-install.html"><NOEMBED></COMMENT>
      </NOEMBED></EMBED>
      </OBJECT>
      <!--
      <APPLET CODE = "MertailApplet.MertailApplet" CODEBASE = "." ARCHIVE = "MertailApplet.jar"
       ALT = "Your browser understands the applet tag but isn\'t displaying any applet."
       WIDTH = 800 HEIGHT = 600 MAYSCRIPT = "false">
      </APPLET>
      -->
    <!--"END_CONVERTED_APPLET"-->

  • !!!!!!!!Strange applet error!!!!!!!!!!!!

    I have a question. I am currently helping some professors with their programming and the newest task that I have been issued involves a problematic java applet. You see, somebody designed the applet and it worked just fine. Now however, it works only on the server computer. On any other machine, the applet doesn't work properly (the radio buttons are all pressed at the same time, the simulation that is supposed to run does not occur...) When I access the IE explorer's Code Download Error Log, I get this:
    *** Code Download Log entry (18 Jul 2002 @ 00:39:09) ***
    Code Download Error: (hr = 80004004) Operation aborted
    Operation failed. Detailed Information:
    CodeBase: javascript:dontGotIt();
    CLSID: {41695A8E-6414-11D4-8FB3-00D0B7730277}
    Extension:
    Type:
    LOG: Reporting Code Download Completion: (hr:80004004 (FAILED), CLASSID: 41695a8e..., szCODE:(javascript:dontGotIt();), MainType:(null), MainExt:(null))
    --- Detailed Error Log Follows ---
    LOG: Download OnStopBinding called (hrStatus = 80004004 / hrResponseHdr = 0).
    LOG: URL Download Complete: hrStatus:80004004, hrOSB:0, hrResponseHdr:0, URL:(javascript:dontGotIt();)
    LOG: Reporting Code Download Completion: (hr:80004004 (FAILED), CLASSID: 41695a8e..., szCODE:(javascript:dontGotIt();), MainType:(null), MainExt:(null))
    Is it just the JVM being different on different machines or is it something else? Thanks a lot!

    Hi,
    Is there a difference between the server computer and the other machines?? So, are the used Explorers (and JVM!) different? The log does not make any sense to me, but the first thing I should check is if it runs properly without the Internet Explorer: so, try to run the applet using the command-prompt Appletviewer. Running an applet using the prompt could give you perhaps more information about what class or object has been crashed...
    Good luck!

  • Strange firmware situation

    I checked the apple article that explains the latest firmware updates for intel macs.
    http://docs.info.apple.com/article.html?artnum=303880
    What is strange is that mine should look like this...
    MacBook Pro (Core 2 Duo 15-inch) MBP22.00A5.B00 1.12f5
    My SMC version is correct (1.12f5) but instead of the boot ROM version for the 15 inch, it actually has the boot ROM version of a MPB C2D 17-inch (MBP21.00A5.B01).
    I am not having any issues. However, I wonder if it could cause problems in the future.

    I have the same thing on my MBP 15"...
    Peter

  • Strange foreclosure situation

    I'm in a strange position.  In 2009 I went through a foreclosure.   Long story short, a few years later that foreclosure was found to be part of the wrongful foreclosures by several banks and was part of the federal settlement.  One of the terms of the settlement was that the foreclosure and any negative reporting regarding the foreclosure would be removed from the credit reports of affected individuals, which it has been.  There is no record of the foreclosure in any of my credit reports.  In fact, there is no record of any mortgage at all in any of my credit reports.  The thing is, I am not in the process of becoming a licensed mortgage banker, and part of the licensing is to disclose certain financial information.  I responded yes to the question "have you had foreclosure action brought against you in the past 10 years?"  However, now I am wondering if I am answering this question correctly.  With it wiped from my credit report, is it still considered to have happened?  Do I need to disclose it?  I have also heard from others that they are unable to get new mortgages without their credit reports accurately reflecting the foreclosure.  Sounds crazy!

    This is an ethical question related to your future employment. Yes, the foreclosures were wrongful. But in a literal sense, it is true that a "foreclosure action" was brought against you--even if it was a wrongful one. The most straight-forward thing to do seems to be to disclose the foreclosure but mention that it was invalidated. Cite the case.

  • Strange spam situation.

    Starting a few days ago, I've been getting spammed a couple times a day. The weird thing is the "To:" field always reads something different (none of them being my e-mail address). Here are the ones I've gotten so far:
    [email protected]
    [email protected]
    [email protected]
    [email protected]
    Only thing I can see is that most start with an 'm', same as my e-mail address. What's the story on this?

    An email will be sent to any address listed in the To, Cc, and Bcc fields; the Bcc field is only visible to the sender, and is often used by spam and opt-in newsletters.
    (24880)

  • Strange font situation in Keynote

    I just upgraded to Yosemite and the latest version of keynote. I opened a presentation I previously created in the last version of Keynote and a weird thing is happening with fonts not appearing correctly. I attached 2 screenshots to illustrate what's happening, I drew red circles on the one to show where its happening, the other is pretty apparent.

    Seems to have something to do with the Character Styles, getting the same thing there.

  • Wallstreet strange battery situation

    Having a problem with a battery with wallstreet. Was supposed to work in another wallstreet, but cannot verify. Inserted battery into 10.2.8 and read 86% and charging. Charged to 100% and had 4 lit LED lights. Unplugged the AC and worked off battery for about 10 minutes and then complete shutdown. Connected AC and rebooted, battery at 96% and charging and charged to 100%. Once again removed AC and lasted about 2 minutes and then complete shutdown. Rebooted and now battery shows 100% all the time and if I remove the AC, it goes to immediate shutdown. Boot into 9.2.1 and run the battery reset v2. It goes straight into the reset without asking to reboot. It says the battery is reset. I remove the battery, wait a few minutes, and reinsert the battery. I have a battery icon with white on the top third, blue on the last two third, and a red line with arrow on the bottom. No lightning bolt for recharging, after about 3 minutes it goes to a solid red battery. And now the test button only shows one blinking LED light. Reset PRAM and Power Unit does not do any good. Any suggestions?

    Jean,
    Your internal rechargeable backup battery will not cause this behavior. Your symptoms are typical of a dying lithium ion battery. There are two important measurements with batteries...volts and amperes. The Jeremey CSM is measuring volts but not amperes; it also will not measure watts if selected.
    On my 800MHz iBook running OSX, I installed a utility called 'coconutBattery' and it measures mAh (milliamperehours). When new, my iBook battery had a 4000 mAh capacity, but is now down to 1842 mAh with a corresponding drop in runtime. However, the battery still charges to a full 16.4 volts. Your battery still charges to 15 volts but it no longer has any capacity (mAh) left. Also, a new battery will probably charge to 16.5 volts, at least the replacement I bought for my Wallstreet does. I think you can be safe in replacing the battery
    By the way, I don't know of any utility that measures battery amperes in OS 9.x.

  • Strange flicker situation

    Hello All
    I have used stll video images before and I have used the flicker filter to get rid of the video flicker or jitter that you get with still images.
    But I have this flicker problem I can't get rid of. I added a couple of matte shot to the timeline. So the first video track was a full screen black and white image. The second track was a still of a person that I cut out with a matte filter (Tom's 50 point matte which is really excellent by the way). To that matte shot I added a drop shadow. So the still matte image is fine, but it's the drop shadow that flickers. I have tried every thing but can't seem to get rid of it.
    Does anyone have any ideas?
    Mike

    Hello Al,
    Yes, I have tried that filter.
    Mike

  • Applet loading in different Browsers

    Hi...We are currently developing an applet thas is loaded into an embedded server from LANTRONIX (WiPort). We have been experienced randomly problems like classNotFound ClassNotDefFound.
    This applet must run on IE Firefox Netscape Navigator and Opera. Strangely applet works well only in Opera browser.
    Errors seems to be related to client side LAN speed. (If embedded web server is accessed from a 10Mbits LAN only Opera can run the applet. If webServer is accessed from a 100Mbits connection, all browsers can load tthe applet.)
    We read about different classloader for every browser, can it be related to the problem?
    Classes are compressed into .cab files.
    Is there any way to check class laoding into the html code.
    Thanks in advance.

    Are you sure IE6 is using Sun's plugin 6?
    If I'm right, IE is using M$'s JRE plugin by default, leading to crappy and unpredicable behavior.

  • Compilation error in PL/SQL

    Hi All,
    Please find the strange query situation in PLSQL.
    If i run the query without PLSQL block (i.e. declar begin end) it runs well and insert data
    in table but if put the same query in PLSQL block it gives compilation error.
    Following is the spool
    SQL> select * from v$version;
    BANNER                                                                                                                                     
    Oracle8i Enterprise Edition Release 8.1.7.4.0 - Production                                                                                 
    PL/SQL Release 8.1.7.4.0 - Production                                                                                                      
    CORE     8.1.7.0.0     Production                                                                                                                  
    TNS for IBM/AIX RISC System/6000: Version 8.1.7.4.0 - Production                                                                           
    NLSRTL Version 3.4.1.0.0 - Production                                                                                                      
    SQL> insert into smcbom_load_hours_temp
      2  select data_set_name,deptclass,dept,smcbom_flex_budget.get_period(v_date) v_period,sum(v_hr),-1,sysdate,-1,sysdate
      3  from (
      4  select plan_level,sp.data_set_name,
      5  sp.value1,smcbom_flex_budget.calculate_period_days(sp.period1),inweight ,
      6  usagerate ,operationseq,percent,
      7  sbov.group_id,sp.alloy,sp.planner_code,
      8  sbov.days,sbov.totaloffsetdays,deptclass,dept,
      9  decode(plan_level,1,(sp.value14/smcbom_flex_budget.calculate_period_days(sp.period14)) * (percent/100) * inweight * usagerate *
    10  (SELECT MAX(INWEIGHT)
    11  FROM  SMCBOM_BOM_OPERATION_VIEW
    12  WHERE ALLOY=sbov.alloy
    13  AND   PLANNER_CODE=sbov.planner_code
    14  AND   PLAN_LEVEL = 0
    15  AND   GROUP_ID = sbov.group_id ),
    16  0,(sp.value14/smcbom_flex_budget.calculate_period_days(sp.period14)) * (percent/100) * inweight * usagerate ,
    17  1) v_hr,
    18  smcbom_flex_budget.get_start_date(sp.period14)+sbov.totaloffsetdays v_date,
    19  sum(-sbov.totaloffsetdays)
    20  over (partition by sp.alloy,sp.planner_code,sbov.group_id
    21  order by plan_level asc,operationseq desc)  new_offset
    22  from smcbom_bom_operation_view sbov,smcbom_sales_prod_forecasts sp
    23  where sbov.alloy= sp.alloy
    24  and   sbov.planner_code=sp.planner_code
    25  and group_id=521136
    26  )
    27  group by data_set_name,deptclass,dept,smcbom_flex_budget.get_period(v_date);
    23 rows created.
    SQL> commit;
    Commit complete.
    SQL> declare
      2  begin
      3  insert into smcbom_load_hours_temp
      4  select data_set_name,deptclass,dept,smcbom_flex_budget.get_period(v_date) v_period,sum(v_hr),-1,sysdate,-1,sysdate
      5  from (
      6  select plan_level,sp.data_set_name,
      7  sp.value1,smcbom_flex_budget.calculate_period_days(sp.period1),inweight ,
      8  usagerate ,operationseq,percent,
      9  sbov.group_id,sp.alloy,sp.planner_code,
    10  sbov.days,sbov.totaloffsetdays,deptclass,dept,
    11  decode(plan_level,1,(sp.value14/smcbom_flex_budget.calculate_period_days(sp.period14)) * (percent/100) * inweight * usagerate *
    12  (SELECT MAX(INWEIGHT)
    13  FROM  SMCBOM_BOM_OPERATION_VIEW
    14  WHERE ALLOY=sbov.alloy
    15  AND   PLANNER_CODE=sbov.planner_code
    16  AND   PLAN_LEVEL = 0
    17  AND   GROUP_ID = sbov.group_id ),
    18  0,(sp.value14/smcbom_flex_budget.calculate_period_days(sp.period14)) * (percent/100) * inweight * usagerate ,
    19  1) v_hr,
    20  smcbom_flex_budget.get_start_date(sp.period14)+sbov.totaloffsetdays v_date,
    21  sum(-sbov.totaloffsetdays)
    22  over (partition by sp.alloy,sp.planner_code,sbov.group_id
    23  order by plan_level asc,operationseq desc)  new_offset
    24  from smcbom_bom_operation_view sbov,smcbom_sales_prod_forecasts sp
    25  where sbov.alloy= sp.alloy
    26  and   sbov.planner_code=sp.planner_code
    27  and group_id=521136
    28  )
    29  group by data_set_name,deptclass,dept,smcbom_flex_budget.get_period(v_date);
    30  end;
    31  /
    (SELECT MAX(INWEIGHT)
    ERROR at line 12:
    ORA-06550: line 12, column 2:
    PLS-00103: Encountered the symbol "SELECT" when expecting one of the following:
    ( - + mod not null others <an identifier>
    <a double-quoted delimited-identifier> <a bind variable> avg
    count current exists max min prior sql stddev sum variance
    execute forall time timestamp interval date
    <a string literal with character set specification>
    <a number> <a single-quoted SQL string>
    ORA-06550: line 22, column 6:
    PLS-00103: Encountered the symbol "(" when expecting one of the following:
    , from
    SQL> spool off;

    In some versions of Oracle (certainly all of the 8.x versions and earlier, and possibly some of the earlier 9 versions) the SQL parsers in the SQL engine and in the PL/SQL engine were different. Some features that worked directly in SQL did not work in PL/SQL. Scalar sub-queries were one of those things.
    You have three options. You can try to re-write the insert statement to eliminate the PL/SQL unimplemented feature. You can create a view in the database for the SELECT part of the insert statement then use that view in the insert. finally, and least desirable, you can build the whole statment as a string, and use EXECUTE IMMEDIATE to run it in PL/SQL.
    HTH
    John

  • Upside down video

    Hello,
    i generate a DVD with Adobe Encore. everything was ok until watching the video. In fact, the video were upsidedown ?!?
    I think i forget to do something or the automatic encoding is not the right choice ... my origin video is .avi.
    Thank you to help me on this strange turnaround situation.
    Melanie

    Melanie,
    As Jeff suggests, DivX (and Xvid) can cause this sort of problem. The file extension "AVI" is just a wrapper. All sorts of CODECs might be used in its creation. A freeware program, G-Spot, can tell you all about the file and also what CODECs are used, plus whether you have them properly installed on your system: www.headbands.com/gspot.
    Let us know what it tells you about your AVI file, please.
    Hunt

  • Sql_id in gv$sort_usage vs gv$session

    I've caught a strange(?) situation here.
    select sql_id from gv$sort_usage where session_addr='000000046A1932F0'; -- gives me 5bqt08ckavskx
    where as
    select sql_id from gv$session where saddr='000000046A1932F0'; -- gives me 1rztpy7a92vpn
    Because of this, I am not able to find the correct query which is consuming lots of temp segments. Well, actually, I am catching up those queries when things are apparent but I am now caught in a situation where two queries are somewhat similar and getting me confused. Why gv$sort_usage and gv$session are giving me different queries and which query is the one that is actually taking the huge temp segments?
    Any help is appreciated.
    Thanks
    gtcol

    You might find useful information in DBA_TEMP_FILES :
    http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:374218170986#76977305391283 (warning: long thread ;) ,but many alternatives)
    http://download.oracle.com/docs/cd/B19306_01/server.102/b14231/tspaces.htm#sthref1323
    Also dbms_xplan can be used to show you the estimated temp space needed by a query, using column temp_space from the plan_table:
    http://download.oracle.com/docs/cd/B19306_01/server.102/b14211/ex_plan.htm#g30946

Maybe you are looking for