Easy to Learn Java: Programming Articles, Examples and Tips

Start with Java in a few days with Java Lessons or Lectures


Code Examples

Java Tools

More Java Tools!

Java Forum

All Java Tips


Submit News
Search the site here...
Search the JavaFAQ.nu
1000 Java Tips ebook

1000 Java Tips - Click here for the high resolution copy!1000 Java Tips - Click here for the high resolution copy!

Java Screensaver, take it here

Free "1000 Java Tips" eBook is here! It is huge collection of big and small Java programming articles and tips. Please take your copy here.

Take your copy of free "Java Technology Screensaver"!.

Java: TextPad Editor

JavaFAQ Home » Java Installation, tunning, options... Go to all tips in Java Installation, tunning, options...

Bookmark and Share

Downloading TextPad

A free, trial version of TextPad can be downloaded from www.textpad.com .


  1. Install a JDK, downloadable from java.sun.com.
  2. Install TextPad.


There no critical preferences that need changing, but they can be set by selecting the Configure > Preferences menu item. Some things you might wish to set:

Set the Startup directory to where your files are normally located.
Document Classes > Java > Tabulation
Set the default tab spacing to 4, indent size to 4, and check both the Convert new tabs to spaces and Convert existing tabs to spaces when saving files. Tabs should generally not be used in programming because the size of tabs is not universal so someone else looking at your program will often see a mess
----- Continues (click the link below)

Entering. compiling, and executing your Java program in Textpad

  1. Type or paste your Java program source code into the large text pane.
  2. Putting the programs directly on your desktop is not a good idea. Create a folder / directory for all of your cmis102a work in it, and a separate directory for each program. The little bit of extra work to create separate directories prevents unwanted interactions between old and new programs. It can save endless hours of frustration. This is not just an academic neatness obsession - it comes from seeing students who were unable to complete their assigments because of old-file pollution.
  3. Save it in a file with EXACTLY the same name as the "class" with an extension of ".java". The "class" name is not the name of the course you're taking, but the name following the word "class" in the Java source code) If the program has this class in it
        class InitialTest {
           . . .
    It must be saved in a file called InitialTest.java .

    Save the file in a directory for this program.

  4. Compile (perform the translation process from source code to machine code) by selecting the Tools > Compile Java menu item. If there are errors (there usually will be at first), you can go back and forth between the "Command Results" and the source code by clicking on each of them in the top left pane. Continue with this process until it compiles correctly.
  5. Run the program by choosing Tools > Run Java Application menu item. You will be using one of these to styles of interaction (Input-Output) at the beginning.
    • Console Ouput (System.out.println(...)). This will open a DOS Command Window and you will see your text output, followed by "Press any key to continue . . .". Your program is done!
    • Dialogbox Output (JOptionPane.showMessageDialog). A dialog box will appear in the middle of your window. Click OK to close it.

TextPad FAQ

  1. Q: TextPad can't find the Java compiler. What's wrong?

    A: When TextPad can't find the Java compiler, there are two common causes.

    1. You installed TextPad before the Java compiler. You MUST install Java first. Uninstall TextPad (from the System control panel) and reinstall it.
    2. You didn't install the Java JDK, maybe you only have the Java JRE. If you installed Java 5 is should install by default in
      C:Program FilesJavajdk1.5.0_01

      There will also be a "jre" (Java Runtime Environment), which is appropriate, but be sure there is a "jdk" (Java Development Kit).

  2. Q: Can I run my Java program like a normal application?

    A: No. TextPad translates the .java files into .class files which can not be run by double-clicking them. Some IDE's (eg, NetBeans) will produce double-clickable .jar files, and there are programs which will package your Java files into a .exe file.

 Printer Friendly Page  Printer Friendly Page
 Send to a Friend  Send to a Friend

.. Bookmark and Share

Search here again if you need more info!
Custom Search

Home Code Examples Java Forum All Java Tips Books Submit News, Code... Search... Offshore Software Tech Doodling

RSS feed Java FAQ RSS feed Java FAQ News     

    RSS feed Java Forums RSS feed Java Forums

All logos and trademarks in this site are property of their respective owner. The comments are property of their posters, all the rest 1999-2006 by Java FAQs Daily Tips.

Interactive software released under GNU GPL, Code Credits, Privacy Policy