Logo 
Search:

Java Answers

Ask Question   UnAnswered
Home » Forum » Java       RSS Feeds
  Question Asked By: Nisha Gor   on Dec 26 In Java Category.

  
Question Answered By: Funsani Chalthoum    on Dec 26

I think the following solution might help you.
Since class1 and class2 are classes,don't specify any import
statements as only packages can be imported.but before compiling
class2 make sure you have set  the classpath  to class1.


suppose if u have arranged your file as follows :
c:\Demo\class1.java
&
c:\Trial\class2.java

then before compiling class2.java set the classpath as
set classpath=.;c:\demo

Share: 

 

This Question has 3 more answer(s). View Complete Question Thread

 
Didn't find what you were looking for? Find more on problem with class import Or get search suggestion and latest updates.


Tagged: