<bherbst65@hotmail.com> wrote...
> This snip has been depreciated. And the warning
> displayed is below that.
> 1 warning found:
> File: C:\Documents and Settings\R
> Herbst\Desktop\BlueJProjects\BookMarkingURLS\BookMrkingURLs.java
> [line: 43]
> Warning: [deprecation] action(java.awt.Event,java.lang.Object) in
> java.awt.Component has been deprecated
So, we'll read the message:
- the method "action" in "java.awt.Component" has been deprecated.
Let's see what the docs says about it:
http://java.sun.com/j2se/1.5.0/docs/api/java/awt/Component.html#action(java.awt.
Event,%20java.lang.Object)%20
or
http://tinyurl.com/e3kfc
"Deprecated. As of JDK version 1.1, should register this component as
ActionListener on component which fires action events."
So, what you should do is to let your component implement the interface
ActionListener, and put the code from "action" into another method, called
"actionPerformed" instead.
http://java.sun.com/j2se/1.5.0/docs/api/java/awt/event/ActionListener.html#actio
nPerformed(java.awt.event.ActionEvent)%20
or
http://tinyurl.com/bggrj
// Bjorn A