🔒 Closed Help again sa java poh ty

Status
Not open for further replies.

jayjay12

Enthusiast
sir patulong paano ko e didisplay yung data sa next frame bali pag login ko dapat makikita ko yung info ko example name:akosikamot lastname:akosikasmot
eto code ko sa login
try{
String sql="select * from Autogenerate where username=? AND password=? ";
pst=conn.prepareStatement(sql);
pst.setString(1,username.getText());
pst.setString(2,password.getText());
rs=pst.executeQuery();
if(rs.next()){
JOptionPane.showMessageDialog(null,"username and passwword Matched");
nextframe frame = newnextframe();
frame.setVisible(true);
}
else if(attempt!=4){
JOptionPane.showMessageDialog(null,"Please Enter the Correct username and password "+attempt);
attempt++;
}
else{
JOptionPane.showMessageDialog(null,"Please Try Again ");
System.exit(0);
}
}catch(SQLException | HeadlessException e){
JOptionPane.showMessageDialog(null,e);

}
 
Status
Not open for further replies.

About this Thread

  • 4
    Replies
  • 576
    Views
  • 4
    Participants
Last reply from:
jayjay12

Trending Topics

Online now

Members online
1,072
Guests online
1,962
Total visitors
3,034

Forum statistics

Threads
2,286,629
Posts
29,039,130
Members
1,217,084
Latest member
mugiwarataro
Back
Top