importing 'my' packages

My name is John and I an new to this forum.

Would like some input from someone on importing user defined packages - something which I am having difficulties with.

As of yet - I have been unable to import any of my packages successfully. Javac cannot find them.

They are in a directory with the same name as the package, all package members are in that directory and the directory path just below my package directory is in the Classpath variable in autoexec.bat which the computer started up from. The package declaration is the first line in package member files and the import statements are 'import packagename.membername(or *);'

I am using J2SDK 1.4.2_06 and have had no other problems with it. As long as any .java files are in the current directory as where I use javac from, everything compiles normally.

I need to start organising my classes into packages and directories but so far have been unable to do so.

If you think you know why or just have any suggestions about how to do this please reply.

Regards

John

[1078 byte] By [Dractema] at [2007-10-2 20:20:08]
# 1

> They are in a directory with the same name as the

> package, all package members are in that directory

> and the directory path just below my package

> directory is in the Classpath variable in

> autoexec.bat which the computer started up from.

There's your problem. The CLASSPATH should contain the directory which contains your uppermost package, e.g. if you have package com.ejp and /usr/ejp/projects/src/com/ejp then CLASSPATH should contain /usr/ejp/projects/src.

ejpa at 2007-7-13 23:02:25 > top of Java-index,Developer Tools,Java Compiler...