Solved

diffirent behaviour between IE40  and Navigator 404

Posted on 1998-06-28
2
161 Views
Last Modified: 2010-03-30
SDK 1.01
Development platform Win95
I write some code :import java.applet.*;
import java.awt.*;

public class j2 extends Applet
{
      Button bt=new Button("Quit");
      TextArea ta=new TextArea(" ");
           public void init()
      {
       
              add(bt);
              add(ta);
                  resize(420, 240);
      }

      public boolean handleEvent(Event evt)
      {
      switch(evt.id)
      {
      case Event.MOUSE_DOWN :
            if(evt.metaDown())
             ta.appendText("Mouse right down\r\n");
            else
             ta.appendText("Mouse down\r\n");
      return true;
      default :
            return false;
      }
}


}
in Navigator when I click right button at anywhere in the applet a property sheet and a string "Mouse right down" appear (it mean I can handle that event)
but in IE40 if I click right button on "Quit" button or on text area string "Mouse right down " doesn't appear .
what wrong with my code ?
Thanks in advance.
0
Comment
Question by:tungsim
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 

Author Comment

by:tungsim
ID: 1223918
Edited text of question
0
 
LVL 1

Accepted Solution

by:
rprice032897 earned 50 total points
ID: 1223919
tungsim,

Check your IE4 settings.  I compiled this (JDK 1.1.6), put it on a page and it ran fine in IE4 (ver. 4.72.2106.8).

You do, however, need to update the deprecated methods in the applet.

appendText is now append.

handleEvent has also been deprecated with the changes to the 1.1 event model.  The JDK docs tell how to convert.

The applet does indeed run well on IE4, so I would look toward browser/machine/system settings for an answer.

Rick Price
r_price@mailexcite.com
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
Introduction This article is the second of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers the basic installation and configuration of the test automation tools used by…
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
Viewers will learn about the different types of variables in Java and how to declare them. Decide the type of variable desired: Put the keyword corresponding to the type of variable in front of the variable name: Use the equal sign to assign a v…
Suggested Courses

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question