1. Home
  2. Computing & Technology
  3. Java

Building Your First Java Applet

By , About.com Guide

3 of 10

Save the File

Save the File

Microsoft product screen shot(s) reprinted with permission from Microsoft Corporation.

Save your program file as “FirstApplet.java”. Make sure the filename you use is correct. If you look at the code you will see the statement:

public class FirstApplet extends Applet {

It’s an instruction to call the applet class “FirstApplet”. The filename must match this class name, and have an extension of “.java”. If your file is not saved as "FirstApplet.java", the Java compiler will complain and not compile your applet.

Explore Java
About.com Special Features

Holiday Central

What to eat, where to go, fun things to do and how to save money on the perfect gifts. More >

Family Tech Center

Stay connected and entertained with reviews on tips on the latest HDTVs, cellphones and more. More >

  1. Home
  2. Computing & Technology
  3. Java
  4. Tutorials
  5. Save the File

©2009 About.com, a part of The New York Times Company.

All rights reserved.