private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton1ActionPerformed
        
        
        clear();
        
        if(txtId.getText().equals(""))
        {
            
            lblId.setText("Please Enter ID");
            lblId.setForeground(Color.red);
        }
        
        
        else
        if(!convert(txtId.getText()))
        {
        //    clear();
            lblId.setText("Please Insert ID in integer form");
            lblId.setForeground(Color.red);
        }
        
        if(txtName.getText().equals(""))
        {
          //  clear();
            lblName.setText("Please Enter Name");
            lblName.setForeground(Color.red);
        }
        
        if(txtGuardian.getText().equals(""))
        {
            //clear();
            lblGname.setText("Please Enter Guardian Name");
            lblGname.setForeground(Color.red);
        }
        
        if(txtsStandard.getText().equals(""))
        {
            //clear();
            lblStandard.setText("Please Enter Standard");
            lblStandard.setForeground(Color.red);
        }
        
        
        else
        if(!convert(txtsStandard.getText()))
        {
             // clear();
            lblStandard.setText("Please Insert Standard in integer form");
            lblStandard.setForeground(Color.red);
        }
        
        if(txtNumber.getText().equals(""))
        {
            // clear();
            lblNumber.setText("Please Enter Number");
            lblNumber.setForeground(Color.red);
        }
        
        else
        if(!convert(txtNumber.getText()))
        {
            // clear();
            lblNumber.setText("Please Insert Number in integer form");
            lblNumber.setForeground(Color.red);
        }
        
        
        
        else
        {
            id = Integer.parseInt(txtId.getText());
            name = txtName.getText();
            guardian_name = txtGuardian.getText();
            standard = Integer.parseInt(txtsStandard.getText());
            contact_number = Integer.parseInt(txtNumber.getText());
            
            DBConnect.addUser(id, name, guardian_name, standard, contact_number);
            
            JOptionPane.showMessageDialog(this,"User added successfully");
            
            txtId.setText("");
            txtGuardian.setText("");
            txtName.setText("");
            txtNumber.setText("");
            txtsStandard.setText("");
            
            
             lblGname.setText("");
             lblId.setText("");
             lblName.setText("");
             lblNumber.setText("");
             lblStandard.setText("");

        
        }
        
        
        
        
        
    }//GEN-LAST:event_jButton1ActionPerformed