Member Avatar for bigBob888

Hello all,
I am new to java and programming. You will be able to tell that by my post. I have a program that needs to take info from my textField and store it in an 2d array. Then do calculations and output the calculated data into a textArea. So far I can input,and store. Right now however I am just trying to print the stored data in my array in the textArea. (one step at a time)
my enter button sends it. my runReport button calculates and prints it. This is a swing() program using a GUI builder(netBeans)
I am not sure if I have given enough info to formulate a refrence fo me to look at but I hope someone out there figures out what I am talking about.(lol)

public class swing extends javax.swing.JFrame {

    
    int r = 0;
    double time;
    double dollars;
    double totalDollars;
    double totalTime;
    double aveWage = (totalTime/totalDollars)*60;
    double [][] tutorInfo = new double [100][2];

    

    /** Creates new form swing */
    public swing() {
            
        initComponents();

    }
       
          

    private void enterInfoActionPerformed(java.awt.event.ActionEvent evt) {                                          
        // TODO add your handling code here:

            String tutorTime = timeInMinutes.getText();
            time = Double.parseDouble(tutorTime);
            timeInMinutes.setText("");
            
            String tutorDollars = paymentInDollars.getText();
            dollars = Double.parseDouble(tutorDollars);
            paymentInDollars.setText("");


            tutorInfo [r][0] = time;
            tutorInfo [r][1] = dollars;
            r++;


    }                                         
    private void runReportActionPerformed(java.awt.event.ActionEvent evt) {                                          
        // TODO add your handling code here:all of my compoutations go here
        
        jTextArea1.setText("answer: " + tutorInfo[r][0]);
        jTextArea1.setText("answer2: " + tutorInfo [r][1]);
Member Avatar for bigBob888

Hello all,
I am new to java and programming. You will be able to tell that by my post. I have a program that needs to take info from my textField and store it in an 2d array. Then do calculations and output the calculated data into a textArea. So far I can input,and store. Right now however I am just trying to print the stored data in my array in the textArea. (one step at a time)
my enter button sends it. my runReport button calculates and prints it. This is a swing() program using a GUI builder(netBeans)
I am not sure if I have given enough info to formulate a refrence fo me to look at but I hope someone out there figures out what I am talking about.(lol)

public class swing extends javax.swing.JFrame {

    
    int r = 0;
    double time;
    double dollars;
    double totalDollars;
    double totalTime;
    double aveWage = (totalTime/totalDollars)*60;
    double [][] tutorInfo = new double [100][2];

    

    /** Creates new form swing */
    public swing() {
            
        initComponents();

    }
       
          

    private void enterInfoActionPerformed(java.awt.event.ActionEvent evt) {                                          
        // TODO add your handling code here:

            String tutorTime = timeInMinutes.getText();
            time = Double.parseDouble(tutorTime);
            timeInMinutes.setText("");
            
            String tutorDollars = paymentInDollars.getText();
            dollars = Double.parseDouble(tutorDollars);
            paymentInDollars.setText("");


            tutorInfo [r][0] = time;
            tutorInfo [r][1] = dollars;
            r++;


    }                                         
    private void runReportActionPerformed(java.awt.event.ActionEvent evt) {                                          
        // TODO add your handling code here:all of my compoutations go here
        
        jTextArea1.setText("answer: " + tutorInfo[r][0]);
        jTextArea1.setText("answer2: " + tutorInfo [r][1]);

How could I make this more clear?

Member Avatar for bigBob888

Is this a dumb question or am I so far off track no one understands what I am asking??

Thanks for nothing daniweb
<<<<<<****** finger. now I will delete my act. have fun *****
I

Even if people tried to explain to you why there was no answer, you wouldn't understand.

That's pretty poor ascii art.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.