Academic Java    Java Tutorial  >  Applets  >  showStatus()

showStatus() Example

Java showStatus EXAMPLE output If the user has chosen to show the Status Bar in their browser then messages can be put there from an applet.

The showStatus() method would do it for this applet, if the applet was running in a browser.
// showStatus() Example
import java.awt.*;
import javax.swing.*;

class ShowStatusExample extends JApplet {

   @Override public void paint(Graphics g) {
      super.paint(g);

      g.setColor(Color.blue);

      g.fillOval(100,100,100,100);

      showStatus("showing the blue ball");

   }

}