Sponsored Content
Full Discussion: Java import problem
Top Forums Programming Java import problem Post 302426246 by Luke Bonham on Tuesday 1st of June 2010 07:56:09 AM
Old 06-01-2010
Java import problem

In a default package, there are BankTest.java and package bank wich contains Account.class .

Code:
 // File: BankTest.java

import bank.*; 
 
public class BankTest { 
 
  public static void main(String[] args) 
  { 
    Account account; 
 
    ...
  } 
}

Trying to compile BankTest.java, terminal reports this error:

Code:
luke@luke-desktop:~/Desktop/Java/ex08/ex08_3$ javac BankTest.java
BankTest.java:14: cannot access bank.Account
bad class file: ./bank/Account.class
class file contains wrong class: Account
Please remove or make sure it appears in the correct subdirectory of the classpath.
    Account account;
    ^
1 error

What's the problem?

EDIT: I managed to solve the problem, there were some package declaration missing

Last edited by Luke Bonham; 06-01-2010 at 01:54 PM..
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Java vm problem

I am using Redhat 7.2. I am trying to install LimeWireLinux. I downloaded the latest versions of LimeWireLinux and JavaVM. I have been trough Limewire, and Sun's setup documents and have done the workarounds for any known problems. My problem is: I get the following error when tring to install the... (3 Replies)
Discussion started by: jeremiebarber
3 Replies

2. Shell Programming and Scripting

ksh script and java problem

I have a problem with the execution of a ksh as deamon on linux. I explain you first the context. We have developped a Java program that execute every minutes an external (that we don't have developped) program with a config file in parameter. The Java program is runned as deamon with a perl... (0 Replies)
Discussion started by: adrian.mihai
0 Replies

3. OS X (Apple)

Java resousebundle problem

Hi Masters, I am runing a java application on Mac os x10.4, java version 1.5. I had this errors regarding chinese language issue. Could anyone have a hint? Thanks a ton. > java -classpath clinic.jar com.scsl.main.MyClinic Exception in thread "main" java.util.MissingResourceException: Can't... (0 Replies)
Discussion started by: mskcc
0 Replies

4. Shell Programming and Scripting

problem in java process

Hi, My operating system is centOS. I am running a java process on this os. But my process is killed automatically before completion. The timing of process killing is uncertain. Please help me. Thanks in advance, (0 Replies)
Discussion started by: Mrs. Deswal
0 Replies

5. Shell Programming and Scripting

Problem with java in crontab

Hello everybody, I have made a java program which runs when i do : java telemesures But when i want to put it in a cron i do /j2sdk1.4.1/bin/java -cp :/web/WEB-INF/classes/Dany4/ telemesures i have got Exception in thread "main" java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver ... (2 Replies)
Discussion started by: totollix
2 Replies

6. Programming

Java sting up path problem

Hi java programmers I'm a newbee to the Java. Could please help me to set the path correctly. I'm getting the following error. ----jGRASP exec: javac -g C:\Documents and Settings\bogugk\Desktop\HelloWorldApp.java ----jGRASP wedge2 error: command "javac" not found. ---- This command... (1 Reply)
Discussion started by: repinementer
1 Replies

7. Shell Programming and Scripting

Mysql import problem

Dear folks, i am importing a database since yesterday that is innodb tablespace, the space of dump file is 4GB, almost 24 pass out it is not yet complete. What should i do to import it fastly. I have disable foreign key check because it have some issues so thats why i am importing it with source... (2 Replies)
Discussion started by: learnbash
2 Replies

8. Programming

can i have an optimal solution for this java code ? Facing Java heap space problem even at 3GB heaps

My desired output is run: for this 1 for this 2 for this 3 for this 4 for this 5 for this 1,2 1->2 for this 2,3 2->3 for this 3,4 3->4 for this 4,5 4->5 for this 1,2,3 1->2,3 (2 Replies)
Discussion started by: vaibhavkorde
2 Replies

9. Programming

Java 7 installation problem

Hi, I am trying to install java7.6 on redhat 6.2 but got the below error message. In fact this error comes up for all the supported OS of JDK 7 and JRE 7. I am running this as root and I dont have any other Java version installed. # rpm -i jre-7u6-linux-x64.rpm Unpacking JAR files... ... (5 Replies)
Discussion started by: nvk_vinoth
5 Replies

10. UNIX and Linux Applications

Problem in import & expdp Dump file

Hi all, i face a problem on (oracle database) installed on server Linux i need to export back as dump file, when i try to export give me the below error. # expdp system/oracle directory=test dumpfile=Prodfb20150311.dmp logfile=Prodfb20150311.log FULL=y Export: Release 11.2.0.1.0 -... (2 Replies)
Discussion started by: clerck
2 Replies
KTOBLZCHECK(1)						      General Commands Manual						    KTOBLZCHECK(1)

NAME
ktoblzcheck - Check Account and BLZ (bank routing code) SYNOPSIS
ktoblzcheck [--returncode] [--file=<datafile>] <bank-id> <account-id> DESCRIPTION
This manual page documents briefly the ktoblzcheck application. ktoblzcheck is a program that will check a given account and blz for the bank being valid and the account being valid using some checksum calculations, if supported for that particular bank. The output is the clear-text name of the bank specified by <bank-id>, and whether the given <account-id> is a valid account number at this bank. OPTIONS
<bank-id> This is the Bankleitzahl (bank routing id), actually it is the account-id of that particular bank at the Deutsche Bundesbank. <account-id> This is the account number you wish to verify. If the checksum method of the bank specified by the <bank-id> is supported, you will get the account-id verified, i.e. if it is a valid account-id at that particular bank. --returncode If given, the result is returned via the returncode and no output on the terminal. The following returncodes are possible: 0: account and bank are ok 1: unknown, e.g. checksum not implemented or such 2: account and/or bank not ok 3: bank not found --file=<datafile> Specifies the file with the bankdata. This file can be obtained via the internet from the Deutsche Bundesbank on address http://www.bundesbank.de/zahlungsverkehr/zahlungsverkehr_bankleitzahlen_download.php Beware! This page is in German only. BUGS
No bugs are known at this time. Only certain checksum algorythms are supported as of now, so please don't complain if you always get "unknown" as return value. AUTHOR
This manual page was written by Jens Gecius <jens@gecius.de> for the Debian GNU/Linux system. Authors of ktoblzcheck are Fabian Kaiser <fabian@openhbci.de> and Christian Stimming <stimming@tuhh.de>. August 3, 2003 KTOBLZCHECK(1)
All times are GMT -4. The time now is 05:48 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy