This week's giveaway is in the Programmer Certification (OCPJP) forum.
We're giving away four copies of Java Mock Exams (software) and have David Mayer on-line!
See this thread for details.
Win a copy of Java Mock Exams (software) this week in the Programmer Certification (OCPJP) forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Package does not exist::Pls. help me out

Sabyasachi Mitra
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear Friends,

I am facing a problem related to package.

I have directory structure like this


i am keeping all of my source code in Source\....

and all of my class files are in class\...

I have one java program called in d:\appl\source\test\mainclass folder and package test.maiclass.

Now one more program in d:\appl\source\test\subclass called, in this program i am importing test.mainclass as priminsuflic extends primins class from d:\appl\class\test\mainclass.

Now when i am trying to compile, it gives a error that package test not found.

I set my classpath like this:


One more thing: i am using CodeGuide IDE for java, is there any issue with that ?? i am using Win2k prof and changing classpath in controlpanel->system->env.variable.

Can anybody pls. help me,i am not getting where its going wrong.

[ March 07, 2005: Message edited by: Sabyasachi Mitra ]
Nischal Tanna
Ranch Hand
Posts: 182
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
mainclass shud have a package declaration like package appl.source.test and not package test.maiclass

Neways to test the whole prog can u plz post ur code?. Also the exception stack trace?
[ March 07, 2005: Message edited by: Nischal Tanna ]
Happiness is not a goal ... it's a by-product of a life well lived - Eleanor Roosevelt. Tiny ad:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!