473,320 Members | 1,952 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

java.lang.NoClassDefFoundError

Hi,
I am j madhu sudana rao working as a analyst programmer computer based learning sdn bhd in malaysia.Now i am Netbeans 5.0 version and also database mysql5.0 and i am using jar file mysql-connector-java-3.1.12.

I take two Jtextfields and Jbutton.

when click button i want display the records from mysql database,but i got following error

java.lang.NoClassDefFoundError: org/aspectj/lang/Signature

import java.sql.*;
import javax.swing.*;
import java.awt.*;
import java.sql.DriverManager;
import java.net.*;
import java.sql.SQLException;

private void btn_displayActionPerformed(java.awt.event.ActionEv ent evt) {
// TODO add your handling code here:
try {
System.out.println("ok");
Class.forName("com.mysql.jdbc.Driver").newInstance ();
System.out.println("ok");
String url = "jdbc:mysql://localhost:3306/asset";
Connection conn = DriverManager.getConnection(url,"root","123456");
Statement stmt = conn.createStatement();
ResultSet rs;
rs = stmt.executeQuery("SELECT username,password FROM user");

// while ( rs.next() )
// {
//String lastName = rs.getString("Lname");
// System.out.println(lastName);

rs.next();
txt_username.setText(rs.getString("username"));
txt_password.setText(rs.getString("password"));

// }

conn.close();
}
catch (Exception e)
{
System.err.println("Got an exception! ");
System.err.println(e.getMessage());
}


}

Please help me as early as possible

Tq
J madhu
Apr 28 '06 #1
0 2242

Sign in to post your reply or Sign up for a free account.

Similar topics

11
by: Lem | last post by:
I get the error Exception in thread "main" java.lang.NoClassDefFoundError when I type java app2 in the command prompt. I've tried moving to the jre directory and typed java c:\app2\app2, but it...
2
by: Stefano Bianchi | last post by:
Ciao, I need to start a java form compiler from linux. The script that comes with the program simply says (after some checks): java -classpath Packager.jar:Filler.jar -jar EPT.jar However,...
1
by: ptaz | last post by:
Hi I'm trying to run a web page but I get the following error. Ca anyone please tell me a solution to this. Thanks Ptaz HTTP Status 500 - type Exception report
1
by: greg.knaddison | last post by:
Hi, I'm trying to use the httpclient within Jython (see http://jakarta.apache.org/commons/httpclient/ for more information on the httpclient). My Jython version is: Jython 2.1 on...
4
by: jmitch89 | last post by:
I don't why I get this error: Exception in thread "main" java.lang.NoClassDefFoundError The statement below works just fine: java -cp...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.