Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/315.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
输出从JFrame更改为Java结果_Java_Swing_Netbeans_Jframe - Fatal编程技术网

输出从JFrame更改为Java结果

输出从JFrame更改为Java结果,java,swing,netbeans,jframe,Java,Swing,Netbeans,Jframe,我在NetBeans中运行了一个JFrame来测试它,突然,输出从JFrame的显示变为: Java结果:-1073740940 我不知道是什么原因导致了这种情况,因为我没有更改run方法中的任何内容,它影响了我所有的JFrame程序。有人知道这是什么原因吗?这是程序中的一个小故障,还是我无意中切换了NetBeans的一个我不知道的设置 更新: 下面是某个人请求的程序代码,但正如我前面所说的,它会影响使用JFrame的多个项目 /* * To change this license h

我在NetBeans中运行了一个JFrame来测试它,突然,输出从JFrame的显示变为:

Java结果:-1073740940

我不知道是什么原因导致了这种情况,因为我没有更改
run
方法中的任何内容,它影响了我所有的JFrame程序。有人知道这是什么原因吗?这是程序中的一个小故障,还是我无意中切换了NetBeans的一个我不知道的设置

更新:

下面是某个人请求的程序代码,但正如我前面所说的,它会影响使用JFrame的多个项目

    /*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package imeannumbers;

import javax.swing.BorderFactory;
import javax.swing.border.TitledBorder;

/**
 *
 * @author Kanto Ruki
 */
public class Main extends javax.swing.JFrame {

    /**
     * Creates new form Main
     */
    boolean decimalUsed = false;

    public Main() {
        initComponents();
    }

    /**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">                          
    private void initComponents() {

        tabGrouping = new javax.swing.JTabbedPane();
        tabNumPad = new javax.swing.JPanel();
        txtBox = new javax.swing.JTextField();
        btnOne = new javax.swing.JButton();
        btnTwo = new javax.swing.JButton();
        btnThree = new javax.swing.JButton();
        btnFour = new javax.swing.JButton();
        btnFive = new javax.swing.JButton();
        btnSix = new javax.swing.JButton();
        btnSeven = new javax.swing.JButton();
        btnEight = new javax.swing.JButton();
        btnNine = new javax.swing.JButton();
        btnDecimal = new javax.swing.JButton();
        btnZero = new javax.swing.JButton();
        btnEnter = new javax.swing.JButton();
        tabAchievements = new javax.swing.JScrollPane();
        jPanel1 = new javax.swing.JPanel();
        lbl00 = new javax.swing.JLabel();
        lbl01 = new javax.swing.JLabel();
        lbl03 = new javax.swing.JLabel();
        lbl05 = new javax.swing.JLabel();
        lbl07 = new javax.swing.JLabel();
        lbl13 = new javax.swing.JLabel();
        jPanel3 = new javax.swing.JPanel();
        jPanel4 = new javax.swing.JPanel();

        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
        setTitle("I Mean Numbers");

        txtBox.setEditable(false);
        txtBox.setHorizontalAlignment(javax.swing.JTextField.RIGHT);
        txtBox.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.LOWERED));

        btnOne.setText("1");
        btnOne.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnOneActionPerformed(evt);
            }
        });

        btnTwo.setText("2");
        btnTwo.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnTwoActionPerformed(evt);
            }
        });

        btnThree.setText("3");
        btnThree.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnThreeActionPerformed(evt);
            }
        });

        btnFour.setText("4");
        btnFour.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnFourActionPerformed(evt);
            }
        });

        btnFive.setText("5");
        btnFive.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnFiveActionPerformed(evt);
            }
        });

        btnSix.setText("6");
        btnSix.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnSixActionPerformed(evt);
            }
        });

        btnSeven.setText("7");
        btnSeven.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnSevenActionPerformed(evt);
            }
        });

        btnEight.setText("8");
        btnEight.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnEightActionPerformed(evt);
            }
        });

        btnNine.setText("9");
        btnNine.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnNineActionPerformed(evt);
            }
        });

        btnDecimal.setText(".");
        btnDecimal.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnDecimalActionPerformed(evt);
            }
        });

        btnZero.setText("0");
        btnZero.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnZeroActionPerformed(evt);
            }
        });

        btnEnter.setText("Enter");
        btnEnter.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnEnterActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout tabNumPadLayout = new javax.swing.GroupLayout(tabNumPad);
        tabNumPad.setLayout(tabNumPadLayout);
        tabNumPadLayout.setHorizontalGroup(
            tabNumPadLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(tabNumPadLayout.createSequentialGroup()
                .addGap(82, 82, 82)
                .addGroup(tabNumPadLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addGroup(tabNumPadLayout.createSequentialGroup()
                        .addComponent(btnDecimal, javax.swing.GroupLayout.PREFERRED_SIZE, 73, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(btnZero, javax.swing.GroupLayout.PREFERRED_SIZE, 73, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(btnEnter, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                    .addGroup(tabNumPadLayout.createSequentialGroup()
                        .addComponent(btnSeven, javax.swing.GroupLayout.PREFERRED_SIZE, 73, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(btnEight, javax.swing.GroupLayout.PREFERRED_SIZE, 73, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(btnNine, javax.swing.GroupLayout.PREFERRED_SIZE, 73, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(tabNumPadLayout.createSequentialGroup()
                        .addComponent(btnFour, javax.swing.GroupLayout.PREFERRED_SIZE, 73, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(btnFive, javax.swing.GroupLayout.PREFERRED_SIZE, 73, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(btnSix, javax.swing.GroupLayout.PREFERRED_SIZE, 73, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(tabNumPadLayout.createSequentialGroup()
                        .addComponent(btnOne, javax.swing.GroupLayout.PREFERRED_SIZE, 73, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(btnTwo, javax.swing.GroupLayout.PREFERRED_SIZE, 73, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(btnThree, javax.swing.GroupLayout.PREFERRED_SIZE, 73, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addComponent(txtBox))
                .addContainerGap(77, Short.MAX_VALUE))
        );
        tabNumPadLayout.setVerticalGroup(
            tabNumPadLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(tabNumPadLayout.createSequentialGroup()
                .addGap(20, 20, 20)
                .addComponent(txtBox, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(18, 18, 18)
                .addGroup(tabNumPadLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(btnOne, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(btnTwo, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(btnThree, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(tabNumPadLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(btnFour, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(btnFive, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(btnSix, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(tabNumPadLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(btnSeven, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(btnEight, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(btnNine, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(tabNumPadLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(btnDecimal, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(btnZero, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(btnEnter, javax.swing.GroupLayout.PREFERRED_SIZE, 30, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        tabGrouping.addTab("NumPad", tabNumPad);

        lbl00.setText("??");
        lbl00.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "?????", javax.swing.border.TitledBorder.RIGHT, javax.swing.border.TitledBorder.BOTTOM));

        lbl01.setText("??");
        lbl01.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "?????", javax.swing.border.TitledBorder.RIGHT, javax.swing.border.TitledBorder.BOTTOM));

        lbl03.setText("??");
        lbl03.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "?????", javax.swing.border.TitledBorder.RIGHT, javax.swing.border.TitledBorder.BOTTOM));

        lbl05.setText("??");
        lbl05.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "?????", javax.swing.border.TitledBorder.RIGHT, javax.swing.border.TitledBorder.BOTTOM));

        lbl07.setText("??");
        lbl07.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "?????", javax.swing.border.TitledBorder.RIGHT, javax.swing.border.TitledBorder.BOTTOM));

        lbl13.setText("??");
        lbl13.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "?????", javax.swing.border.TitledBorder.RIGHT, javax.swing.border.TitledBorder.BOTTOM));

        javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
        jPanel1.setLayout(jPanel1Layout);
        jPanel1Layout.setHorizontalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addGap(34, 34, 34)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addComponent(lbl05, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(lbl07, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(lbl13, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addComponent(lbl00, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(lbl01, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(lbl03, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addContainerGap(42, Short.MAX_VALUE))
        );
        jPanel1Layout.setVerticalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(lbl03)
                    .addComponent(lbl01)
                    .addComponent(lbl00))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.CENTER)
                    .addComponent(lbl05)
                    .addComponent(lbl07)
                    .addComponent(lbl13))
                .addContainerGap(141, Short.MAX_VALUE))
        );

        tabAchievements.setViewportView(jPanel1);

        tabGrouping.addTab("Achievements", tabAchievements);

        javax.swing.GroupLayout jPanel3Layout = new javax.swing.GroupLayout(jPanel3);
        jPanel3.setLayout(jPanel3Layout);
        jPanel3Layout.setHorizontalGroup(
            jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 390, Short.MAX_VALUE)
        );
        jPanel3Layout.setVerticalGroup(
            jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 232, Short.MAX_VALUE)
        );

        tabGrouping.addTab("How To Play", jPanel3);

        javax.swing.GroupLayout jPanel4Layout = new javax.swing.GroupLayout(jPanel4);
        jPanel4.setLayout(jPanel4Layout);
        jPanel4Layout.setHorizontalGroup(
            jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 390, Short.MAX_VALUE)
        );
        jPanel4Layout.setVerticalGroup(
            jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGap(0, 232, Short.MAX_VALUE)
        );

        tabGrouping.addTab("About", jPanel4);

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(tabGrouping)
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(tabGrouping)
        );

        pack();
        setLocationRelativeTo(null);
    }// </editor-fold>                        

    private void btnOneActionPerformed(java.awt.event.ActionEvent evt) {                                       
        txtBox.setText(txtBox.getText() + "1");
    }                                      

    private void btnTwoActionPerformed(java.awt.event.ActionEvent evt) {                                       
        txtBox.setText(txtBox.getText() + "2");
    }                                      

    private void btnThreeActionPerformed(java.awt.event.ActionEvent evt) {                                         
        txtBox.setText(txtBox.getText() + "3");
    }                                        

    private void btnFourActionPerformed(java.awt.event.ActionEvent evt) {                                        
        txtBox.setText(txtBox.getText() + "4");
    }                                       

    private void btnFiveActionPerformed(java.awt.event.ActionEvent evt) {                                        
        txtBox.setText(txtBox.getText() + "5");
    }                                       

    private void btnSixActionPerformed(java.awt.event.ActionEvent evt) {                                       
        txtBox.setText(txtBox.getText() + "6");
    }                                      

    private void btnSevenActionPerformed(java.awt.event.ActionEvent evt) {                                         
        txtBox.setText(txtBox.getText() + "7");
    }                                        

    private void btnEightActionPerformed(java.awt.event.ActionEvent evt) {                                         
        txtBox.setText(txtBox.getText() + "8");
    }                                        

    private void btnNineActionPerformed(java.awt.event.ActionEvent evt) {                                        
        txtBox.setText(txtBox.getText() + "9");
    }                                       

    private void btnDecimalActionPerformed(java.awt.event.ActionEvent evt) {                                           
        if (!decimalUsed) {
            txtBox.setText(txtBox.getText() + ".");
            decimalUsed = true;
        }
    }                                          

    private void btnZeroActionPerformed(java.awt.event.ActionEvent evt) {                                        
        txtBox.setText(txtBox.getText() + "0");
    }                                       

    private void btnEnterActionPerformed(java.awt.event.ActionEvent evt) {                                         
        String check = txtBox.getText();

        TitledBorder title = BorderFactory.createTitledBorder("title");
        title.setTitleJustification(TitledBorder.RIGHT);
        title.setTitlePosition(TitledBorder.BOTTOM);

        switch (check) {
            case "00":
                title.setTitle("The Beginning...");
                lbl00.setBorder(title);
                lbl00.setText("00");
                break;
            case "01":
                title.setTitle("Your the First");
                lbl01.setBorder(title);
                lbl01.setText("01");
                break;
            default:
                break;
        }

        decimalUsed = false;
        txtBox.setText("");
    }                                        

    /**
     * @param args the command line arguments
     */
    public static void main(String args[]) {
        /* Set the Nimbus look and feel */
        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
        /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
         * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html 
         */
        try {
            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
                if ("Nimbus".equals(info.getName())) {
                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
                    break;
                }
            }
        } catch (ClassNotFoundException ex) {
            java.util.logging.Logger.getLogger(Main.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (InstantiationException ex) {
            java.util.logging.Logger.getLogger(Main.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (IllegalAccessException ex) {
            java.util.logging.Logger.getLogger(Main.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
            java.util.logging.Logger.getLogger(Main.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        }
        //</editor-fold>

        /* Create and display the form */
        java.awt.EventQueue.invokeLater(new Runnable() {
            public void run() {
                new Main().setVisible(true);
            }
        });
    }

    // Variables declaration - do not modify                     
    private javax.swing.JButton btnDecimal;
    private javax.swing.JButton btnEight;
    private javax.swing.JButton btnEnter;
    private javax.swing.JButton btnFive;
    private javax.swing.JButton btnFour;
    private javax.swing.JButton btnNine;
    private javax.swing.JButton btnOne;
    private javax.swing.JButton btnSeven;
    private javax.swing.JButton btnSix;
    private javax.swing.JButton btnThree;
    private javax.swing.JButton btnTwo;
    private javax.swing.JButton btnZero;
    private javax.swing.JPanel jPanel1;
    private javax.swing.JPanel jPanel3;
    private javax.swing.JPanel jPanel4;
    private javax.swing.JLabel lbl00;
    private javax.swing.JLabel lbl01;
    private javax.swing.JLabel lbl03;
    private javax.swing.JLabel lbl05;
    private javax.swing.JLabel lbl07;
    private javax.swing.JLabel lbl13;
    private javax.swing.JScrollPane tabAchievements;
    private javax.swing.JTabbedPane tabGrouping;
    private javax.swing.JPanel tabNumPad;
    private javax.swing.JTextField txtBox;
    // End of variables declaration                   
}

当错误消息
变量信息不可用时,源代码编译时没有-g选项

您可能已经切换了设置。如果选择项目,并在弹出菜单中选择“属性”,然后选择类别“运行”。有几处房产会把事情搞得一团糟。可以将主类更改为JFrame类以外的类。将平台设置为您尚未安装的JDK版本或etc的安装已中断


调试的最佳方式可能是选择项目,然后选择调试->单步执行或从菜单中按F7。这将启动您的程序,但会立即暂停,这样您就可以通过按F7(单步执行)或F8(单步执行)一行一行地执行程序。如果它开始进入错误的类,则无需修复主类属性。如果它开始正常,但很早就退出,那么在退出之前,您需要仔细查看最后一行。

无意冒犯,但我们不可能神奇地看到您的代码。请查看并改进您的问题。照现在的情况,它很可能会被关闭。@Fildor我已经添加了一个受影响程序的代码。我希望这对我有帮助。我上次使用swing是几十年前的事了,所以我不是最好的来源。但我觉得您应该看看Oracle的Swing教程,以及它们如何为Swing应用程序构建主要方法。@Fildor链接的建议包括“包含足够的代码,以允许其他人重现问题。有关此方面的帮助,请阅读如何创建最小、完整且可验证的示例。”读“刚好够”的部分意味着(对于类似的东西)大约50-100行代码。张贴的代码超过450 LOC。如果你真的需要帮助,就修剪它。我在“no MCVE”的基础上投票关闭。在任何情况下代表“no”。错误似乎是
变量信息不可用,源代码在项目属性对话框中进入
main
runner时编译,没有-g选项,在“类别”列表中选择“编译”下的“生成调试信息”,然后选中标记为“生成调试信息”的复选框并重新编译。默认情况下,该程序已具有“生成调试信息”,我认为在使用该信息再次编译之前,我没有尝试重新编译。这并没有产生任何变化,我可以找到。。。
public static void invokeLater(Runnable runnable) {
    Toolkit.getEventQueue().postEvent(
        new InvocationEvent(Toolkit.getDefaultToolkit(), runnable));
}