javac -cp : cannot find symbol problem [migrated]
- by LivingThing
I have 3 classes CustomerAddress, Customer and CustomerMain.
Customer has a import statement :
import org.abc.customers.CustomerAddress;
While CustomerMain has an import statement :
import org.abc.customers.CustomerAddress;
import org.abc.customers.Customer;
The package for all of these classes are
package org.abc.customer
Now, this program works fine on eclipse but when i try to compile and run on cmd prompt it would not compile
javac CustomerAddress.java
compiles fine
then since Customer depends on CustomerAddress
i give
javac -cp . Customer.java
but the compiler complains
error cannot find symbol CustomerAddress
Thanks