Results 1 to 3 of 3

Thread: Java Learning

  1. #1
    JTUS is offline Member
    Join Date
    Dec 2011
    Posts
    2
    Rep Power
    0

    Default Java Learning

    Greetings,

    I'm just starting to learn the Java language, and have a few simple questions.

    I have installed jre6 and jre7 as well as jdk1.7.0_01 in a folder named Java and subfolders for the jre's.

    I created a folder off the root named greetings and have Hello.java and have ran the javac command properly and then ran the java command with three arg and it worked fine.

    My next level involves import java.io.*;
    How does the application source know where to import the java.io*? I remember seeing something about setting the system.path somehow. Is that why my new source wouldn't find the import? what statement is needed to set the location of the runtime?

    Thanx in advance for any assistance.

    jT

  2. #2
    JTUS is offline Member
    Join Date
    Dec 2011
    Posts
    2
    Rep Power
    0

    Default Re: Java Learning

    Found examples of setting environment variables of the PATH and I set it to the directory of my jre6\bin.... C:\Program Files (x86)\Java\jre6\bin

  3. #3
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    SW Missouri
    Posts
    17,307
    Rep Power
    25

    Default Re: Java Learning

    How does the application source know where to import the java.io*?
    The java.io package is part of Java, you shouldn't need to set the classpath for java to find the class definitions.
    If you are getting errors, please copy and paste here the full text of the console.
    To copy the contents of the command prompt window:
    Click on Icon in upper left corner
    Select Edit
    Select 'Select All' - The selection will show
    Click in upper left again
    Select Edit and click 'Copy'

    Paste here.

Similar Threads

  1. Replies: 12
    Last Post: 06-14-2011, 04:55 PM
  2. Learning Java...
    By Learning Java in forum New To Java
    Replies: 2
    Last Post: 09-24-2010, 09:03 PM
  3. Pls Help me in learning Java
    By SimranK in forum New To Java
    Replies: 6
    Last Post: 06-24-2010, 07:44 PM
  4. Learning Java
    By Derkins in forum New To Java
    Replies: 3
    Last Post: 04-09-2009, 02:46 AM
  5. Learning Java
    By jjoshua2 in forum New To Java
    Replies: 2
    Last Post: 12-20-2008, 02:46 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •